Class: FeduxOrgStdlib::CommandFinder
- Inherits:
-
Object
- Object
- FeduxOrgStdlib::CommandFinder
- Defined in:
- lib/fedux_org_stdlib/command_finder.rb
Direct Known Subclasses
Instance Method Summary collapse
-
#initialize(alternatives:, search_paths:) ⇒ CommandFinder
constructor
Finds path to command.
-
#known_commands ⇒ Object
Return known commands.
-
#path ⇒ Object
Find path to command.
Constructor Details
#initialize(alternatives:, search_paths:) ⇒ CommandFinder
Finds path to command
It also considers other executables for one command
22 23 24 25 |
# File 'lib/fedux_org_stdlib/command_finder.rb', line 22 def initialize(alternatives:, search_paths:) @alternatives = Array(alternatives) @search_paths = Array(search_paths) end |
Instance Method Details
#known_commands ⇒ Object
Return known commands
39 40 41 |
# File 'lib/fedux_org_stdlib/command_finder.rb', line 39 def known_commands @alternatives end |