Class: LLM::Shell::Command::FileImport
- Inherits:
-
Object
- Object
- LLM::Shell::Command::FileImport
- Includes:
- Utils
- Defined in:
- lib/llm/shell/commands/file_import.rb
Class Method Summary collapse
-
.complete(path) ⇒ Array<String>
Completes a path with a wildcard.
Instance Method Summary collapse
-
#initialize(context) ⇒ LLM::Shell::Command::FileImport
constructor
-
#call(*files) ⇒ void
Imports one or more globbed files.
Constructor Details
#initialize(context) ⇒ LLM::Shell::Command::FileImport
22 23 24 |
# File 'lib/llm/shell/commands/file_import.rb', line 22 def initialize(context) @context = context end |
Class Method Details
.complete(path) ⇒ Array<String>
Completes a path with a wildcard.
14 15 16 |
# File 'lib/llm/shell/commands/file_import.rb', line 14 def self.complete(path) Dir["#{path}*"] end |
Instance Method Details
#call(*files) ⇒ void
This method returns an undefined value.
Imports one or more globbed files.
29 30 31 |
# File 'lib/llm/shell/commands/file_import.rb', line 29 def call(*files) Dir[*files].each { import(_1) } end |