Class: Dependencies

Inherits:
SimpleDelegator
  • Object
show all
Includes:
Kernel
Defined in:
dependencies.rb,
dependencies.rbi

Instance Method Summary collapse

Methods included from Kernel

#disk_usage_readable, #ensure_executable!, #ensure_formula_installed!, #exec_browser, #exec_editor, #ignore_interrupts, #interactive_shell, #number_readable, #odebug, #odeprecated, #odie, #odisabled, #ofail, #oh1, #oh1_title, #ohai, #ohai_title, #onoe, #opoo, #paths, #pretty_duration, #pretty_installed, #pretty_outdated, #pretty_uninstalled, #quiet_system, #redact_secrets, #redirect_stdout, #require?, #safe_system, #tap_and_name_comparison, #truncate_text_to_approximate_size, #which, #which_all, #which_editor, #with_custom_locale, #with_env, #with_homebrew_path

Constructor Details

#initialize(*args) ⇒ Dependencies

This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.

Returns a new instance of Dependencies.



10
11
12
# File 'dependencies.rb', line 10

def initialize(*args)
  super(args)
end

Instance Method Details

#==(other) ⇒ Boolean

This is a workaround to enable alias eql? ==

Parameters:

  • other (BasicObject)

Returns:

  • (Boolean)

See Also:



8
# File 'dependencies.rbi', line 8

def ==(other); end

#buildObject

This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.



24
25
26
# File 'dependencies.rb', line 24

def build
  __getobj__.select(&:build?)
end

#defaultObject

This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.



32
33
34
# File 'dependencies.rb', line 32

def default
  build + required + recommended
end

#dup_without_system_depsObject

This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.



36
37
38
# File 'dependencies.rb', line 36

def dup_without_system_deps
  self.class.new(*__getobj__.reject { |dep| dep.uses_from_macos? && dep.use_macos_install? })
end

#eql?Object

This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.



14
# File 'dependencies.rb', line 14

alias eql? ==

#inspectString

This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.

Returns:



41
42
43
# File 'dependencies.rb', line 41

def inspect
  "#<#{self.class.name}: #{__getobj__}>"
end

#optionalObject

This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.



16
17
18
# File 'dependencies.rb', line 16

def optional
  __getobj__.select(&:optional?)
end

This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.



20
21
22
# File 'dependencies.rb', line 20

def recommended
  __getobj__.select(&:recommended?)
end

#requiredObject

This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.



28
29
30
# File 'dependencies.rb', line 28

def required
  __getobj__.select(&:required?)
end