Slash commands
The plugin registers three slash commands. Use them when you want to trigger Sextant explicitly rather than wait for a hook or a skill to decide.
| Command | What it does |
|---|---|
/sextant-grade [paths] | Grade the working tree (or specified paths) and summarize. |
/sextant-init | Run sextant init in the current repo. |
/sextant-explain <rule-id> | Print the markdown body for a rule. |
/sextant-grade
Section titled “/sextant-grade”/sextant-grade/sextant-grade src/parser.rs src/lexer.rsWith no arguments, the command calls grade_diff (working tree vs
merge-base) — the cheap inner-loop grade. With paths, it calls
grade_files against just those paths.
The agent then summarizes:
- Verdict —
approveorrequest_changesand the counts. - Top three findings — severity, rule id, file:line, message.
- Unfamiliar rules — looks them up via
explain_ruleand includes a one-liner. - Next step — most actionable fix. Doesn’t apply fixes unless you ask.
/sextant-init
Section titled “/sextant-init”/sextant-initRuns sextant init in the current working directory. Idempotent —
files already present are skipped unless you pass --force to the CLI
directly (the slash command doesn’t take a flag for this, by design).
After it runs, the agent reports what was created and points you at
follow-up commands: sextant grade, sextant rules list,
sextant rules explain.
/sextant-explain
Section titled “/sextant-explain”/sextant-explain builtin.size.fn-length/sextant-explain project.no-unwrapLooks up the rule whose id matches the argument and renders its markdown body. The body is the authoritative documentation for the rule — why it exists, what trips it, and how to fix a finding.
If the id doesn’t exist, the agent falls back to list_rules and
offers fuzzy matches. Useful when you’ve half-remembered an id.
Authoring your own
Section titled “Authoring your own”Commands live at plugin/commands/<name>.md. Each is a markdown file
with YAML frontmatter:
---description: One-line description shown in /help.argument-hint: "[paths...]"allowed-tools: ["mcp__sextant__grade_diff", "Bash"]---The body of the markdown file is the prompt the agent sees when the
command is invoked, with $ARGUMENTS substituted.
After editing, reload the plugin (/plugin reload sextant) or restart
the session.
See also
Section titled “See also”- Skills — auto-loaded behaviour.
- Pre-commit hook — the commit-time gate.
sextant grade— the underlying CLI.