diff options
| author | Max Howell | 2011-08-25 02:32:41 +0100 |
|---|---|---|
| committer | Max Howell | 2011-08-25 02:32:41 +0100 |
| commit | ab3e6a454433e9d9f0373c02ddd128b55d47a25a (patch) | |
| tree | a74025288494c70911abd44abe3bc9fdf9f87314 /Library | |
| parent | 8cb7090723cd28d54a40788619288d007635effa (diff) | |
| download | homebrew-ab3e6a454433e9d9f0373c02ddd128b55d47a25a.tar.bz2 | |
Output bottles to CWD
Rationale: more typical.
Diffstat (limited to 'Library')
| -rwxr-xr-x | Library/Contributions/examples/brew-bottle.rb | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/Library/Contributions/examples/brew-bottle.rb b/Library/Contributions/examples/brew-bottle.rb index 05ee56d4c..4d91643e0 100755 --- a/Library/Contributions/examples/brew-bottle.rb +++ b/Library/Contributions/examples/brew-bottle.rb @@ -1,9 +1,6 @@ # Builds binary brew package require 'cmd/install' -destination = HOMEBREW_PREFIX + "Bottles" -Dir.mkdir destination unless File.directory? destination - ARGV.each do|formula| # Get the latest version version = `brew list --versions #{formula}`.split.last @@ -16,12 +13,13 @@ ARGV.each do|formula| source = HOMEBREW_CELLAR + formula + version filename = "#{formula}-#{version}-bottle.tar.gz" ohai "Bottling #{formula} #{version}..." + destination = Pathname.pwd HOMEBREW_CELLAR.cd do # Use gzip, faster to compress than bzip2, faster to uncompress than bzip2 # or an uncompressed tarball (and more bandwidth friendly). - safe_system 'tar', 'czf', "#{destination}/#{filename}", "#{formula}/#{version}" - sha1 = Pathname.new("#{destination}/#{filename}").sha1 - ohai "Bottled #{filename}" - ohai "SHA1 #{sha1}" + safe_system 'tar', 'czf', destination/filename, "#{formula}/#{version}" + puts "./#{filename}" + puts "bottle 'https://downloads.sf.net/project/machomebrew/Bottles/#{filename}'" + puts "bottle_sha1 '#{(destination/filename).sha1}'" end end |
