A CLI spellbook of developer incantations.
go build -o grimorio .nix build .#grimorioGrimorio provides two types of commands:
- Cantrips - Deterministic transformations
- Spells - AI-powered features (require Claude CLI)
Format source code files using Language Server Protocol (LSP) servers.
grimorio mending file.go
grimorio mending ./internal/...
grimorio mending --check . # Check only, exit 1 if changes needed
grimorio mending --diff file.py # Show diff without modifyingSupported languages: Go, Python, Rust, C#, TypeScript, JavaScript, HTML, JSON, YAML, Nix, Lua
Requires the appropriate LSP server installed (e.g., gopls, pyright, rust-analyzer).
Transform data between structured formats.
grimorio polymorph data.json --to yaml
grimorio polymorph config.yaml --to toml
grimorio polymorph users.json --to csv -o output.csv
cat data.json | grimorio polymorph --from json --to yamlSupported formats: JSON, YAML, TOML, XML, CSV, Markdown, HTML
Generate conventional commit messages using Claude AI.
grimorio modify-memory # Commit staged changes
grimorio modify-memory -a # Include all changes
grimorio modify-memory -m "context" # Add motivation/context
grimorio modify-memory -n # Dry run, output message only
grimorio modify-memory -s # Split into multiple logical commitsThe -s flag analyzes changes and proposes multiple commit groups, opening an editor to reorder or modify the plan (similar to git rebase -i).
- Go 1.25+
- LSP servers for mending (gopls, pyright, rust-analyzer, etc.)
- Claude CLI for spells
MIT