diff options
| author | Tim D. Smith | 2015-04-02 21:43:28 -0700 |
|---|---|---|
| committer | Tim D. Smith | 2015-04-06 20:26:52 -0700 |
| commit | 5a0ec0c49181569a595fa62d458c4cf16cf060e9 (patch) | |
| tree | ba5c9a098bea7f3aa525fa4ec4c78a8dc56d75e1 | |
| parent | 6370ccf9a81bbd9c0b4ddb6068a91c649529d514 (diff) | |
| download | brew-5a0ec0c49181569a595fa62d458c4cf16cf060e9.tar.bz2 | |
add SoftwareSpec#go_resource
by analogy to similar code in formula.rb.
Permits Homebrew/homebrew#37877. Closes Homebrew/homebrew#38330.
| -rw-r--r-- | Library/Homebrew/formula.rb | 2 | ||||
| -rw-r--r-- | Library/Homebrew/software_spec.rb | 4 |
2 files changed, 5 insertions, 1 deletions
diff --git a/Library/Homebrew/formula.rb b/Library/Homebrew/formula.rb index 39e065a7a..88c5c5449 100644 --- a/Library/Homebrew/formula.rb +++ b/Library/Homebrew/formula.rb @@ -914,7 +914,7 @@ class Formula end def go_resource name, &block - resource name, Resource::Go, &block + specs.each { |spec| spec.go_resource(name, &block) } end def depends_on dep diff --git a/Library/Homebrew/software_spec.rb b/Library/Homebrew/software_spec.rb index f5e81d65e..463129498 100644 --- a/Library/Homebrew/software_spec.rb +++ b/Library/Homebrew/software_spec.rb @@ -85,6 +85,10 @@ class SoftwareSpec end end + def go_resource name, &block + resource name, Resource::Go, &block + end + def option_defined?(name) options.include?(name) end |
