Compile Migrations

Compile SQL migration files into Go source code for embedding in binaries

c9s Updated

File contents

Compile SQL migrations into Go code for all configured dialects.

Steps

  1. Find all rockhopper_*.yaml config files in the project root.
  2. If $ARGUMENTS is provided, use it as the base output directory. Otherwise, use pkg/migrations/<dialect> as the default output path for each dialect.
  3. For each config file, run:
    rockhopper compile --config <config_file> --output <output_dir>
    
  4. Show the generated Go files and confirm compilation succeeded.

c9s/rockhopper/tree/main/.claude/skills/compile-migrations commit cf6ed2ca1b

Frequently asked questions

npx skillmds@latest add c9s/compile-migrations-2