diff options
| author | Jack Nagel | 2013-01-23 00:26:23 -0600 |
|---|---|---|
| committer | Jack Nagel | 2013-01-26 11:37:01 -0600 |
| commit | 70ff06c827ce0da3d3dabe9e9c4927061e6c7f4c (patch) | |
| tree | 4d626df5e580077588bef5cdd0391b3e704eab64 /Library/Homebrew/formula_installer.rb | |
| parent | 26b1b88c974cc902b0e9c2c2b8d17a16335d8462 (diff) | |
| download | brew-70ff06c827ce0da3d3dabe9e9c4927061e6c7f4c.tar.bz2 | |
Refactor option handling internals
Currently we handle options in several ways, and it is hard to remember
what code needs an option string ("--foo"), what needs only the name
("foo") and what needs an Option object.
Now that Option objects can act as strings and be converted to JSON, we
can start using them instead of passing around strings between Formula
objects, Tab objects, and ARGV-style arrays.
The Options class is a special collection that can be queried for the
inclusion of options in any form: '--foo', 'foo', or Option.new("foo").
Diffstat (limited to 'Library/Homebrew/formula_installer.rb')
| -rw-r--r-- | Library/Homebrew/formula_installer.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Library/Homebrew/formula_installer.rb b/Library/Homebrew/formula_installer.rb index 1c312ddfa..0df987f1f 100644 --- a/Library/Homebrew/formula_installer.rb +++ b/Library/Homebrew/formula_installer.rb @@ -208,7 +208,7 @@ class FormulaInstaller ENV['HOMEBREW_ERROR_PIPE'] = write.to_i.to_s args = ARGV.clone - args.concat tab.used_options unless tab.nil? or args.include? '--fresh' + args.concat(tab.used_options.as_flags) unless tab.nil? or args.include? '--fresh' # FIXME: enforce the download of the non-bottled package # in the spawned Ruby process. args << '--build-from-source' |
