diff options
| author | Thomas Maurer | 2017-02-04 18:10:37 +0100 |
|---|---|---|
| committer | Thomas Maurer | 2017-02-04 18:10:37 +0100 |
| commit | 6594650eb1c37170e7d70e7e9c75b48d154e38a9 (patch) | |
| tree | 4775f5d02c21ad46b0b32b885c743d8e58a0affa /Library | |
| parent | 22a37b2f5d3a57ec5732b0dcc8bb0474b4a47700 (diff) | |
| download | brew-6594650eb1c37170e7d70e7e9c75b48d154e38a9.tar.bz2 | |
Pass invalid option names to formula installer
This is the same that happens in the command 'install'. By passing
the invalid option names, we enable the formula installer to output
warnings if necessary.
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Homebrew/cmd/reinstall.rb | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/Library/Homebrew/cmd/reinstall.rb b/Library/Homebrew/cmd/reinstall.rb index 2eb2840a5..586405909 100644 --- a/Library/Homebrew/cmd/reinstall.rb +++ b/Library/Homebrew/cmd/reinstall.rb @@ -25,19 +25,21 @@ module Homebrew backup keg end - options = BuildOptions.new(Options.create(ARGV.flags_only), f.options).used_options + build_options = BuildOptions.new(Options.create(ARGV.flags_only), f.options) + options = build_options.used_options options |= f.build.used_options options &= f.options fi = FormulaInstaller.new(f) - fi.options = options - fi.build_bottle = ARGV.build_bottle? || (!f.bottled? && f.build.build_bottle?) - fi.build_from_source = ARGV.build_from_source? || ARGV.build_all_from_source? - fi.force_bottle = ARGV.force_bottle? - fi.interactive = ARGV.interactive? - fi.git = ARGV.git? - fi.verbose = ARGV.verbose? - fi.debug = ARGV.debug? + fi.options = options + fi.invalid_option_names = build_options.invalid_option_names + fi.build_bottle = ARGV.build_bottle? || (!f.bottled? && f.build.build_bottle?) + fi.build_from_source = ARGV.build_from_source? || ARGV.build_all_from_source? + fi.force_bottle = ARGV.force_bottle? + fi.interactive = ARGV.interactive? + fi.git = ARGV.git? + fi.verbose = ARGV.verbose? + fi.debug = ARGV.debug? fi.prelude oh1 "Reinstalling #{f.full_name} #{options.to_a.join " "}" |
