Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

install: Use CLI::Parser to parse args #5619

Merged
merged 9 commits into from
Jan 29, 2019
16 changes: 0 additions & 16 deletions Library/Homebrew/build_options.rb
Original file line number Diff line number Diff line change
Expand Up @@ -99,22 +99,6 @@ def unused_options
@options - @args
end

# @private
def invalid_options
@args - @options - BuildOptions.formula_install_options
end

# @private
def invalid_option_names
invalid_options.map(&:flag).sort
end

def self.formula_install_options
@formula_install_options ||= ARGV.formula_install_option_names.map do |option_name|
Option.new option_name[2..-1]
end
end

private

def option_defined?(name)
Expand Down
4 changes: 2 additions & 2 deletions Library/Homebrew/cmd/gist-logs.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#: Upload logs for a failed build of <formula> to a new Gist.
#:
#: <formula> is usually the name of the formula to install, but it can be specified
#: in several different ways. See [SPECIFYING FORMULAE](#specifying-formulae).
#: in several different ways.
#:
#: If `--with-hostname` is passed, include the hostname in the Gist.
#:
Expand Down Expand Up @@ -32,7 +32,7 @@ def gist_logs_args
Upload logs for a failed build of <formula> to a new Gist.

<formula> is usually the name of the formula to install, but it can be specified
in several different ways. See [SPECIFYING FORMULAE](#specifying-formulae).
in several different ways.

If no logs are found, an error message is presented.
EOS
Expand Down