Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add rules/diegomarino/awesomic-cursor-rules/pre-commit-reviewgit clone --depth 1 https://github.com/diegomarino/awesomic-cursor-rulesWhat 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 | $0.00000 | $0.00752 |
| Opus 5 | $0.00000 | $0.00376 |
| Sonnet 5 | $0.00000 | $0.00150 |
| Haiku 4.5 | $0.00000 | $0.00075 |
Grade A, and why
pre-commit-review 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 3d 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.
How it starts
The opening of the file, as written. The whole thing — 98 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Things to review before a commit
You should check all the files before commiting them in order to verify different aspects.
Linting
- You should check and fix all the linting errors that the staged files have
- Pay special attention to:
- Proper indentation
- Line length (max 80 characters)
- No unused imports or variables
- No console.log statements in production code
Comments
- You should check (using the format and rules from @comments-javascript.mdc):
- All the comments are updated to display the exact name of imported modules, used params and exported results
- There is no comment in any other language than English
- JSDoc headers are complete for new/modified files
- Function documentation includes examples and error cases
- Error handling sections are up to date
Logging
- Review all logger calls (using the format and rules from @logging.mdc):
- Each log has a clear and meaningful message
- Context is always specified and valid (check @logging.mdc for valid contexts)
- Filename is included in all logs
- Metadata follows the format:
key1=value1 • key2=value2 - Metadata fits in one line (except for error details)
- Log levels are used appropriately:
- ERROR: Only for critical issues requiring immediate attention
- WARN: For unexpected but handled conditions
- INFO: For important operational events (use sparingly)
- DEBUG: For detailed development information
- No sensitive data in logs (passwords, tokens, etc)
- Complex objects are properly formatted in metadata
- Error logs include proper error context and details
Tests
- You should check:
- All the files to be commited have enough unit tests (if they are needed). We don't aim to have 100% test coverage, but we do aim to have enough coverage to be comfortable making changes
- Tests include edge cases and error scenarios
- Test descriptions are clear and meaningful
- Mocks are properly implemented (especially for file system operations)
- All tests pass before committing
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.
- 3d ago First seen · 98 lines · 752 tokens per session scan A 44d5a4db9151
pre-commit-review is a cursor rule published in the GitHub repository diegomarino/awesomic-cursor-rules (10 stars, last pushed 1y ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 752 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.
Other cursor rules, from other repositories
git-commit-attribution
Git commits must use the human developer identity only; never Cursor Agent co-authorship.
git-conventional-commits
Conventional commit messages and logical multi-commit workflow when working with Git.
dos-verify-done-claims-cursorrules-prompt-file
Gate AI done/shipped/fixed claims on ground truth from the DOS kernel (dos verify, dos commit-audit) — git ancestry and the commit's own diff, never the agent's own narration.
pause
Checkpoint the session into git so it survives a close and resumes from any device. Use on "pause", "checkpoint", "cache this session", "save my place", or "I'm stepping away" — writes a handoff, commits work in flight, and pushes.
no-cursor-commit-attribution
Never add Cursor co-author or attribution trailers to git commits or PRs.
git-commits
description: "Reference and apply the git commits skill for Conventional Commit formatting and pre-push checks." alwaysApply: true.