diff options
| author | Jack Nagel | 2014-07-18 15:14:42 -0500 |
|---|---|---|
| committer | Jack Nagel | 2014-07-18 15:15:12 -0500 |
| commit | 99073dad6f57e2684ec5492e6c0a86ec1db5dffe (patch) | |
| tree | eeacc31d1d07a5b503d2d4f10fc84e90d732a69a /Library/Homebrew/cmd | |
| parent | 4a95f48e41cfde4007113d486c90367c1351d4a5 (diff) | |
| download | homebrew-99073dad6f57e2684ec5492e6c0a86ec1db5dffe.tar.bz2 | |
Ask the filename object for the prefix
Diffstat (limited to 'Library/Homebrew/cmd')
| -rw-r--r-- | Library/Homebrew/cmd/bottle.rb | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/Library/Homebrew/cmd/bottle.rb b/Library/Homebrew/cmd/bottle.rb index 8bd1c4b9e..954f6eb78 100644 --- a/Library/Homebrew/cmd/bottle.rb +++ b/Library/Homebrew/cmd/bottle.rb @@ -192,10 +192,7 @@ module Homebrew puts output if ARGV.include? '--rb' - bottle_base = filename.to_s.gsub(bottle_suffix(bottle_revision), '') - File.open "#{bottle_base}.bottle.rb", 'w' do |file| - file.write output - end + File.open("#{filename.prefix}.bottle.rb", "w") { |file| file.write(output) } end end |
