diff --git a/Library/Homebrew/cmd/deps.rb b/Library/Homebrew/cmd/deps.rb index 8186ab1f4736306f9fad729fac63e6ae0bf6d74e..42e50c984a2a7cef786d4030ae90ef5365cd7878 100644 --- a/Library/Homebrew/cmd/deps.rb +++ b/Library/Homebrew/cmd/deps.rb @@ -57,15 +57,8 @@ module Homebrew description: "Switch into the mode used by the `--all` option, but only list dependencies "\ "for each provided <formula>, one formula per line. This is used for "\ "debugging the `--installed`/`--all` display mode." - switch "--formula", "--formulae", - depends_on: "--installed", - description: "Treat all named arguments as formulae." - switch "--cask", "--casks", - depends_on: "--installed", - description: "Treat all named arguments as casks." conflicts "--installed", "--all" - conflicts "--formula", "--cask" formula_options end end @@ -89,13 +82,7 @@ module Homebrew dependents = if args.named.present? sorted_dependents(args.named.to_formulae_and_casks) elsif args.installed? - if args.formula? && !args.cask? - sorted_dependents(Formula.installed) - elsif args.cask? && !args.formula? - sorted_dependents(Cask::Caskroom.casks(config: Cask::Config.from_args(args))) - else - sorted_dependents(Formula.installed + Cask::Caskroom.casks(config: Cask::Config.from_args(args))) - end + sorted_dependents(Formula.installed + Cask::Caskroom.casks(config: Cask::Config.from_args(args))) else raise FormulaUnspecifiedError end @@ -113,14 +100,8 @@ module Homebrew if args.no_named? raise FormulaUnspecifiedError unless args.installed? - sorted_dependents_formulae_and_casks = if args.formula? && !args.cask? - sorted_dependents(Formula.installed) - elsif args.cask? && !args.formula? - sorted_dependents(Cask::Caskroom.casks(config: Cask::Config.from_args(args))) - else - sorted_dependents(Formula.installed + Cask::Caskroom.casks(config: Cask::Config.from_args(args))) - end - pus_deps sorted_dependents_formulae_and_casks, recursive: recursive, args: args + puts_deps sorted_dependents(Formula.installed + Cask::Caskroom.casks(config: Cask::Config.from_args(args))), + recursive: recursive, args: args return end diff --git a/docs/Manpage.md b/docs/Manpage.md index 27525453db7f2e12b602b1539dbb1f2e13fead00..0d7b130b288c6ff6b9de550633b2ce806df71d6d 100644 --- a/docs/Manpage.md +++ b/docs/Manpage.md @@ -129,10 +129,6 @@ show the intersection of dependencies for each formula. List dependencies for all available formulae. * `--for-each`: Switch into the mode used by the `--all` option, but only list dependencies for each provided *`formula`*, one formula per line. This is used for debugging the `--installed`/`--all` display mode. -* `--formula`: - Treat all named arguments as formulae. -* `--cask`: - Treat all named arguments as casks. ### `desc` [*`options`*] (*`text`*|`/`*`text`*`/`|*`formula`*) diff --git a/manpages/brew.1 b/manpages/brew.1 index 2e6304a46156efc685f4aa7c92b78b1e04fc1684..684615bdd0b437a5facc7b101abe1c8924f684a4 100644 --- a/manpages/brew.1 +++ b/manpages/brew.1 @@ -152,14 +152,6 @@ List dependencies for all available formulae\. \fB\-\-for\-each\fR Switch into the mode used by the \fB\-\-all\fR option, but only list dependencies for each provided \fIformula\fR, one formula per line\. This is used for debugging the \fB\-\-installed\fR/\fB\-\-all\fR display mode\. . -.TP -\fB\-\-formula\fR -Treat all named arguments as formulae\. -. -.TP -\fB\-\-cask\fR -Treat all named arguments as casks\. -. .SS "\fBdesc\fR [\fIoptions\fR] (\fItext\fR|\fB/\fR\fItext\fR\fB/\fR|\fIformula\fR)" Display \fIformula\fR\'s name and one\-line description\. Formula descriptions are cached; the cache is created on the first search, making that search slower than subsequent ones\. .