Class: Clag::CommandLineCommandGenerator
- Inherits:
-
Sublayer::Generators::Base
- Object
- Sublayer::Generators::Base
- Clag::CommandLineCommandGenerator
- Defined in:
- lib/clag/generators/command_line_command_generator.rb
Instance Method Summary collapse
- #generate ⇒ Object
-
#initialize(description:) ⇒ CommandLineCommandGenerator
constructor
A new instance of CommandLineCommandGenerator.
- #prompt ⇒ Object
Constructor Details
#initialize(description:) ⇒ CommandLineCommandGenerator
Returns a new instance of CommandLineCommandGenerator.
7 8 9 |
# File 'lib/clag/generators/command_line_command_generator.rb', line 7 def initialize(description:) @description = description end |
Instance Method Details
#generate ⇒ Object
11 12 13 |
# File 'lib/clag/generators/command_line_command_generator.rb', line 11 def generate super end |
#prompt ⇒ Object
15 16 17 18 19 20 21 22 23 24 25 26 27 |
# File 'lib/clag/generators/command_line_command_generator.rb', line 15 def prompt <<-PROMPT You are an expert in command line operations. You are tasked with finding or crafting a command line command to achieve the following: #{@description} Considering best practices, what should be run on the command line to achieve this. If no command is possible, respond with 'unknown' PROMPT end |