Class: WideEvents::Generators::SkillsGenerator

Inherits:
Rails::Generators::Base
  • Object
show all
Defined in:
lib/generators/wide_events/skills/skills_generator.rb

Overview

Copies the agent skills shipped with the gem into .claude/skills/ so coding agents pick up the instrumentation and debugging conventions.

Constant Summary collapse

SKILLS_ROOT =
File.expand_path("../../../../skills", __dir__)

Instance Method Summary collapse

Instance Method Details

#copy_skillsObject



12
13
14
15
16
17
# File 'lib/generators/wide_events/skills/skills_generator.rb', line 12

def copy_skills
  Dir[File.join(SKILLS_ROOT, "*", "SKILL.md")].sort.each do |path|
    name = File.basename(File.dirname(path))
    copy_file File.join(name, "SKILL.md"), ".claude/skills/#{name}/SKILL.md"
  end
end