Class: Claude::Generators::CommandGenerator

Inherits:
Rails::Generators::NamedBase
  • Object
show all
Defined in:
lib/generators/claude/command/command_generator.rb

Instance Method Summary collapse

Instance Method Details

#create_command_fileObject



17
18
19
# File 'lib/generators/claude/command/command_generator.rb', line 17

def create_command_file
  template "command.md.tt", command_path
end

#show_instructionsObject



21
22
23
24
25
26
27
28
29
# File 'lib/generators/claude/command/command_generator.rb', line 21

def show_instructions
  say "\nCommand '#{file_name}' created successfully!", :green
  say "\nLocation: #{command_path}", :blue
  say "\nUsage: /#{file_name}", :yellow
  say "\nNext steps:", :yellow
  say "  1. Edit #{command_path} to add your command logic"
  say "  2. Test with: /#{file_name}"
  say "  3. The command will be auto-loaded by Claude\n"
end