Borrowing it
Nothing to install: this file belongs to nanotaboada/go-samples-gin-restful. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/nanotaboada/go-samples-gin-restful/master/.claude/commands/pre-commit.mdgit clone --depth 1 https://github.com/nanotaboada/go-samples-gin-restfulWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/nanotaboada/go-samples-gin-restful/pre-commit)<a href="https://agentmods.dev/commands/nanotaboada/go-samples-gin-restful/pre-commit"><img src="https://agentmods.dev/badge/commands/nanotaboada/go-samples-gin-restful/pre-commit/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/commands/nanotaboada/go-samples-gin-restful/pre-commit"><img src="https://agentmods.dev/badge/commands/nanotaboada/go-samples-gin-restful/pre-commit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.00750 |
| Opus 5.5 | $0.00000 | $0.00300 |
| Sonnet 5.5 | $0.00000 | $0.00150 |
| Haiku 4.5 | $0.00000 | $0.00075 |
Grade A, and why
pre-commit scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
What it actually says
Before running the checklist, run git fetch origin. If the current branch is behind origin/master, stop and rebase before proceeding.
Run the pre-commit checklist for this project:
-
Update
CHANGELOG.md[Unreleased]section — read the currentCHANGELOG.md, inspectgit diffto understand what changed, then write the appropriate entry under the correct subsection (Added / Changed / Fixed / Removed), referencing the issue number. If the[Unreleased]section already contains an entry that covers these changes (e.g. added during release branch preparation via/pre-release), skip this step. Also skip this step for tooling/maintenance changes with no backing GitHub issue — feature and bug work should already have an issue per this project's SDD workflow, so this exception does not apply to them. -
Run
go fmt ./... -
Note whether
go.mod/go.sumalready have uncommitted changes before runninggo mod tidy(git diff --stat -- go.mod go.sum). Rungo mod tidy, then compare again — if tidy introduced additional changes beyond that baseline, stop and report it — propose committing the tidy result first and wait for my explicit confirmation before doing so. -
Run
go vet ./...— must pass. -
Run
go build -v ./...— must succeed. -
Ask me: were any Swagger annotations modified? If yes, run
swag init. -
Run
go test -v ./... -coverpkg=github.com/nanotaboada/go-samples-gin-restful/service,github.com/nanotaboada/go-samples-gin-restful/controller,github.com/nanotaboada/go-samples-gin-restful/route -covermode=atomic -coverprofile=coverage.out— all tests must pass, target 80%+ coverage for service, controller, route packages. -
If Docker is running, run
docker compose build— must succeed with no errors. Skip this step with a note if Docker Desktop is not running. -
If
coderabbitCLI is installed andcoderabbit review --helpreports--agentsupport, runcoderabbit review --type uncommitted --agent:- If actionable/serious findings are reported, stop and address them before proposing the commit.
- If only nitpick-level findings, report them and continue to the commit proposal.
- If
coderabbitis not installed, or the installed version does not support--agent, skip this step with a note.
Run step 1 (CHANGELOG update), then run steps 2–3 sequentially (stop at step 3 if go.mod or go.sum changed), then ask about step 6 and run swag init first if needed, then run steps 4, 5, and 7 in parallel, run step 8 (docker build), then run step 9 (CodeRabbit review) if available, report the results clearly, then propose a branch name and commit message for my approval using the format type(scope): description (#issue) (max 80 chars; types: feat fix chore docs test refactor ci perf) with the required Co-Authored-By: Claude Sonnet 5 <[email protected]> line. Do not create the branch or commit until I explicitly confirm.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2mo ago First seen · 35 lines · 0 tokens per session scan A cc664a57749e
pre-commit is a command published in the GitHub repository nanotaboada/go-samples-gin-restful (2 stars, last pushed 3d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 750 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
pre-commit compared with commands from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| pre-commitnanotaboada/go-samples-gin-restful | Command | 2 | 3d ago | MIT | A | 0 | Claude Code |
| resolve-conflictsai-sdlc-framework/ai-sdlc | Command | 434 | yesterday | Apache-2.0 | A | 79 | Claude Code |
| code-reviewGoldziher/ai-rulez | Command | 167 | yesterday | MIT | A | 11 | Claude Code |
| releaseexistential-birds/beagle | Command | 85 | 1mo ago | Apache-2.0 | A | 12 | Claude Code |
| releaseGoldziher/ai-rulez | Command | 167 | yesterday | MIT | A | 4 | Claude Code |
| shipGoldziher/ai-rulez | Command | 167 | yesterday | MIT | A | 4 | Claude Code |
| release-tagexistential-birds/beagle | Command | 85 | 1mo ago | Apache-2.0 | A | 11 | Claude Code |