Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,20 @@
require 'rubygems'
require 'rubygems/package_task'

task :compress_binaries do
Dir.glob(File.join(__dir__, 'bin/', '*{x86,amd64}')).each do |path|
sh "upx", "-t", path do |success|
if success
puts "#{path} already compressed, skipping"
else
sh "upx", path
end
end
end
end

task gem: :compress_binaries

spec = eval(File.new("wkhtmltopdf-binary.gemspec").readlines.join("\n"))
Gem::PackageTask.new(spec) do |pkg|
pkg.need_tar = true
Expand Down