Class: Xeno::Generators::ToolGenerator

Inherits:
Rails::Generators::NamedBase
  • Object
show all
Defined in:
lib/generators/xeno/tool/tool_generator.rb

Overview

rails g xeno:tool GetWeather → agent/tools/get_weather.rb (the path supplies the runtime name: get_weather)

Instance Method Summary collapse

Instance Method Details

#create_toolObject



8
9
10
# File 'lib/generators/xeno/tool/tool_generator.rb', line 8

def create_tool
  template "tool.rb.tt", "agent/tools/#{file_name}.rb"
end