mirror of
https://github.com/Homebrew/brew.git
synced 2025-07-14 16:09:03 +08:00
Merge pull request #19000 from Moisan/deps-include-implicit
deps command: add --include-implicit flag
This commit is contained in:
commit
f756ea471b
@ -31,6 +31,8 @@ module Homebrew
|
|||||||
description: "Show the union of dependencies for multiple <formula>, instead of the intersection."
|
description: "Show the union of dependencies for multiple <formula>, instead of the intersection."
|
||||||
switch "--full-name",
|
switch "--full-name",
|
||||||
description: "List dependencies by their full name."
|
description: "List dependencies by their full name."
|
||||||
|
switch "--include-implicit",
|
||||||
|
description: "Include implicit dependencies used to download and unpack source files"
|
||||||
switch "--include-build",
|
switch "--include-build",
|
||||||
description: "Include `:build` dependencies for <formula>."
|
description: "Include `:build` dependencies for <formula>."
|
||||||
switch "--include-optional",
|
switch "--include-optional",
|
||||||
@ -102,6 +104,7 @@ module Homebrew
|
|||||||
!args.tree? &&
|
!args.tree? &&
|
||||||
!args.graph? &&
|
!args.graph? &&
|
||||||
!args.HEAD? &&
|
!args.HEAD? &&
|
||||||
|
!args.include_implicit? &&
|
||||||
!args.include_build? &&
|
!args.include_build? &&
|
||||||
!args.include_test? &&
|
!args.include_test? &&
|
||||||
!args.include_optional? &&
|
!args.include_optional? &&
|
||||||
|
@ -37,6 +37,9 @@ module Homebrew
|
|||||||
switch "--eval-all",
|
switch "--eval-all",
|
||||||
description: "Evaluate all available formulae and casks, whether installed or not, to show " \
|
description: "Evaluate all available formulae and casks, whether installed or not, to show " \
|
||||||
"their dependents."
|
"their dependents."
|
||||||
|
switch "--include-implicit",
|
||||||
|
description: "Include formulae that have <formula> as an implicit dependency to " \
|
||||||
|
"download and unpack source files"
|
||||||
switch "--include-build",
|
switch "--include-build",
|
||||||
description: "Include formulae that specify <formula> as a `:build` dependency."
|
description: "Include formulae that specify <formula> as a `:build` dependency."
|
||||||
switch "--include-test",
|
switch "--include-test",
|
||||||
@ -73,6 +76,7 @@ module Homebrew
|
|||||||
|
|
||||||
use_runtime_dependents = args.installed? &&
|
use_runtime_dependents = args.installed? &&
|
||||||
!used_formulae_missing &&
|
!used_formulae_missing &&
|
||||||
|
!args.include_implicit? &&
|
||||||
!args.include_build? &&
|
!args.include_build? &&
|
||||||
!args.include_test? &&
|
!args.include_test? &&
|
||||||
!args.include_optional? &&
|
!args.include_optional? &&
|
||||||
|
@ -11,6 +11,7 @@ module DependenciesHelpers
|
|||||||
|
|
||||||
def args_includes_ignores(args)
|
def args_includes_ignores(args)
|
||||||
includes = [:required?, :recommended?] # included by default
|
includes = [:required?, :recommended?] # included by default
|
||||||
|
includes << :implicit? if args.include_implicit?
|
||||||
includes << :build? if args.include_build?
|
includes << :build? if args.include_build?
|
||||||
includes << :test? if args.include_test?
|
includes << :test? if args.include_test?
|
||||||
includes << :optional? if args.include_optional?
|
includes << :optional? if args.include_optional?
|
||||||
|
@ -53,6 +53,9 @@ class Homebrew::Cmd::Deps::Args < Homebrew::CLI::Args
|
|||||||
sig { returns(T::Boolean) }
|
sig { returns(T::Boolean) }
|
||||||
def graph?; end
|
def graph?; end
|
||||||
|
|
||||||
|
sig { returns(T::Boolean) }
|
||||||
|
def include_implicit?; end
|
||||||
|
|
||||||
sig { returns(T::Boolean) }
|
sig { returns(T::Boolean) }
|
||||||
def include_build?; end
|
def include_build?; end
|
||||||
|
|
||||||
|
@ -26,6 +26,9 @@ class Homebrew::Cmd::Uses::Args < Homebrew::CLI::Args
|
|||||||
sig { returns(T::Boolean) }
|
sig { returns(T::Boolean) }
|
||||||
def formulae?; end
|
def formulae?; end
|
||||||
|
|
||||||
|
sig { returns(T::Boolean) }
|
||||||
|
def include_implicit?; end
|
||||||
|
|
||||||
sig { returns(T::Boolean) }
|
sig { returns(T::Boolean) }
|
||||||
def include_build?; end
|
def include_build?; end
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user