reinstall: handle new options

Since we are loading options as Formula#build from tab, we will have to explicitly read
options from ARGV as well.

Fixes #3066.

Closes #537.

Signed-off-by: Xu Cheng <xucheng@me.com>
This commit is contained in:
Xu Cheng 2016-07-18 18:03:27 +08:00
parent 820b6347b8
commit d7ee541293
No known key found for this signature in database
GPG Key ID: C2A3860FA0B459CE

View File

@ -11,7 +11,8 @@ module Homebrew
end
def reinstall_formula(f)
options = f.build.used_options
options = BuildOptions.new(Options.create(ARGV.flags_only), f.options).used_options
options |= f.build.used_options
notice = "Reinstalling #{f.full_name}"
notice += " with #{options * ", "}" unless options.empty?