Remove cat_without_underscores bottle methods.

This commit is contained in:
Mike McQuaid 2013-05-25 16:02:07 +01:00
parent 6f6d4e5894
commit a75aff246e
3 changed files with 0 additions and 17 deletions

View File

@ -40,10 +40,6 @@ class Formula
unless bottle.checksum.nil? || bottle.checksum.empty?
@bottle = bottle
bottle.url ||= bottle_url(self)
if bottle.cat_without_underscores
bottle.url.gsub!(MacOS.cat.to_s,
MacOS.cat_without_underscores.to_s)
end
end
end

View File

@ -76,15 +76,12 @@ end
class Bottle < SoftwareSpec
attr_writer :url
# TODO: Can be removed when all bottles migrated to underscored cat symbols.
attr_reader :cat_without_underscores
def initialize
super
@revision = 0
@prefix = '/usr/local'
@cellar = '/usr/local/Cellar'
@cat_without_underscores = false
end
# Checksum methods in the DSL's bottle block optionally take
@ -101,9 +98,6 @@ class Bottle < SoftwareSpec
if @#{cksum}.has_key? MacOS.cat
@checksum = @#{cksum}[MacOS.cat]
elsif @#{cksum}.has_key? MacOS.cat_without_underscores
@checksum = @#{cksum}[MacOS.cat_without_underscores]
@cat_without_underscores = true
end
end
EOS

View File

@ -27,13 +27,6 @@ module MacOS extend self
end
end
# TODO: Can be removed when all bottles migrated to underscored cat symbols.
def cat_without_underscores
possibly_underscored_cat = cat
return nil unless possibly_underscored_cat
cat.to_s.gsub('_', '').to_sym
end
def oldest_cpu
if Hardware::CPU.type == :intel
if Hardware::CPU.is_64_bit?