Skip to content
Snippets Groups Projects
Commit 2bfc7904 authored by L. E. Segovia's avatar L. E. Segovia
Browse files

Simplify cask help check

parent a8ee54a3
No related branches found
No related tags found
No related merge requests found
......@@ -78,15 +78,10 @@ begin
# - a help flag is passed AND a command is matched
# - a help flag is passed AND there is no command specified
# - no arguments are passed
if empty_argv || help_flag
# - if cmd is Cask, let Cask handle the help command instead
if (empty_argv || help_flag ) && cmd != "cask"
require "cmd/help"
if cmd == "cask"
# Let Cask handle the help command
Homebrew.send cmd.to_s.tr("-", "_").downcase
exit 0
else
Homebrew.help cmd, empty_argv: empty_argv
end
Homebrew.help cmd, empty_argv: empty_argv
# `Homebrew.help` never returns, except for external/unknown commands.
end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment