Cursor rule
.cursor/rules/common-code-review.mdcCursor rules
Quality
65/100
Scores the file, not the repository.Length
553 words
14 headings · 1 code blocksRepository
6
— · pushed 80 days agoLast changed
3 days ago
First indexed 3 days ago.1# Code Review Standards23## Purpose45Code review ensures quality, security, and maintainability before code is merged. This rule defines when and how to conduct code reviews.67## When to Review89**MANDATORY review triggers:**1011- After writing or modifying code12- Before any commit to shared branches13- When security-sensitive code is changed (auth, payments, user data)14- When architectural changes are made15- Before merging pull requests1617**Pre-Review Requirements:**1819Before requesting review, ensure:2021- All automated checks (CI/CD) are passing22- Merge conflicts are resolved23- Branch is up to date with target branch2425## Review Checklist2627Before marking code complete:2829- [ ] Code is readable and well-named30- [ ] Functions are focused (<50 lines)31- [ ] Files are cohesive (<800 lines)32- [ ] No deep nesting (>4 levels)33- [ ] Errors are handled explicitly34- [ ] No hardcoded secrets or credentials35- [ ] No console.log or debug statements36- [ ] Tests exist for new functionality37- [ ] Test coverage meets 80% minimum3839## Security Review Triggers4041**STOP and use security-reviewer agent when:**4243- Authentication or authorization code44- User input handling45- Database queries46- File system operations47- External API calls48- Cryptographic operations49- Payment or financial code5051## Review Severity Levels5253| Level | Meaning | Action |54|-------|---------|--------|55| CRITICAL | Security vulnerability or data loss risk | **BLOCK** - Must fix before merge |56| HIGH | Bug or significant quality issue | **WARN** - Should fix before merge |57| MEDIUM | Maintainability concern | **INFO** - Consider fixing |58| LOW | Style or minor suggestion | **NOTE** - Optional |5960## Agent Usage6162Use these agents for code review:6364| Agent | Purpose |65|-------|---------|66| **code-reviewer** | General code quality, patterns, best practices |67| **security-reviewer** | Security vulnerabilities, OWASP Top 10 |68| **typescript-reviewer** | TypeScript/JavaScript specific issues |69| **python-reviewer** | Python specific issues |70| **go-reviewer** | Go specific issues |71| **rust-reviewer** | Rust specific issues |7273## Review Workflow7475```761. Run git diff to understand changes772. Check security checklist first783. Review code quality checklist794. Run relevant tests805. Verify coverage >= 80%816. Use appropriate agent for detailed review82```8384## Common Issues to Catch8586### Security8788- Hardcoded credentials (API keys, passwords, tokens)89- SQL injection (string concatenation in queries)90- XSS vulnerabilities (unescaped user input)91- Path traversal (unsanitized file paths)92- CSRF protection missing93- Authentication bypasses9495### Code Quality9697- Large functions (>50 lines) - split into smaller98- Large files (>800 lines) - extract modules99- Deep nesting (>4 levels) - use early returns100- Missing error handling - handle explicitly101- Mutation patterns - prefer immutable operations102- Missing tests - add test coverage103104### Performance105106- N+1 queries - use JOINs or batching107- Missing pagination - add LIMIT to queries108- Unbounded queries - add constraints109- Missing caching - cache expensive operations110111## Approval Criteria112113- **Approve**: No CRITICAL or HIGH issues114- **Warning**: Only HIGH issues (merge with caution)115- **Block**: CRITICAL issues found116117## Integration with Other Rules118119This rule works with:120121- [testing.md](testing.md) - Test coverage requirements122- [security.md](security.md) - Security checklist123- [git-workflow.md](git-workflow.md) - Commit standards124- [agents.md](agents.md) - Agent delegation125
Also in ThanhTrunggDEV/DontBeLazy
Diff this repo’s formatsOne repository carrying more than one format is the comparison this product exists for: does anyone actually write different content in each file, or is one a copy of the other?
| Repository | Format | Stack | Covers | Score | Changed |
|---|---|---|---|---|---|
| ThanhTrunggDEV/DontBeLazy.cursor/rules/zh-agents.mdc · 6 | Cursor rules | no sections | 50/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/zh-patterns.mdc · 6 | Cursor rules | api | 30/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.agent/AGENTS.md · 6 | AGENTS.md | buildteststylearch+4 | 77/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/AGENTS.md · 6 | AGENTS.md | buildteststylearch+4 | 77/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/common-agents.mdc · 6 | Cursor rules | agent-behaviour | 50/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/common-coding-style.mdc · 6 | Cursor rules | style | 54/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/common-development-workflow.mdc · 6 | Cursor rules | gitagent-behaviour | 39/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/common-git-workflow.mdc · 6 | Cursor rules | lint-formatgitagent-behaviour | 43/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/common-hooks.mdc · 6 | Cursor rules | styletypessecuritydo-not | 36/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/common-patterns.mdc · 6 | Cursor rules | lint-formatstyleapi | 52/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/common-performance.mdc · 6 | Cursor rules | buildperformance | 48/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/common-security.mdc · 6 | Cursor rules | security | 39/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/common-testing.mdc · 6 | Cursor rules | testtesting-strategyagent-behaviour | 34/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/cpp-coding-style.mdc · 6 | Cursor rules | lint-formatstyle | 52/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/cpp-hooks.mdc · 6 | Cursor rules | buildlint-formatdeployment | 60/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/cpp-patterns.mdc · 6 | Cursor rules | style | 54/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/cpp-security.mdc · 6 | Cursor rules | securityperformancedo-not | 73/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/cpp-testing.mdc · 6 | Cursor rules | testtesting-strategy | 55/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/csharp-coding-style.mdc · 6 | Cursor rules | lint-formatstyletypes | 66/100 | 3 days ago | |
| ThanhTrunggDEV/DontBeLazy.cursor/rules/csharp-hooks.mdc · 6 | Cursor rules | no sections | 33/100 | 3 days ago |
Diff against .cursor/rules/zh-agents.mdc Diff against .cursor/rules/zh-patterns.mdc Diff against .agent/AGENTS.md Diff against .cursor/AGENTS.md Diff against .cursor/rules/common-agents.mdc Diff against .cursor/rules/common-coding-style.mdc Diff against .cursor/rules/common-development-workflow.mdc Diff against .cursor/rules/common-git-workflow.mdc Diff against .cursor/rules/common-hooks.mdc Diff against .cursor/rules/common-patterns.mdc Diff against .cursor/rules/common-performance.mdc Diff against .cursor/rules/common-security.mdc Diff against .cursor/rules/common-testing.mdc Diff against .cursor/rules/cpp-coding-style.mdc Diff against .cursor/rules/cpp-hooks.mdc Diff against .cursor/rules/cpp-patterns.mdc Diff against .cursor/rules/cpp-security.mdc Diff against .cursor/rules/cpp-testing.mdc Diff against .cursor/rules/csharp-coding-style.mdc Diff against .cursor/rules/csharp-hooks.mdc
Similar configs
Same format, overlapping stack, ranked by quality.
| Repository | Format | Stack | Covers | Score | Changed |
|---|---|---|---|---|---|
| hiromaily/go-crypto-wallet.cursor/rules/typescript.mdc · 126 | Cursor rules | setupbuildtestlint-format+6 | 100/100 | 3 days ago | |
| TechSquidTV/Hermes.cursor/rules/10-hermes-api.mdc · 45 | Cursor rules | testlint-formatstylearch+5 | 100/100 | 3 days ago | |
| markstev/mark-starter.cursor/rules/frontend.mdc · 0 | Cursor rules | setuptestlint-formatstyle+6 | 99/100 | 3 days ago | |
| Allymahmoud/case-intake-platform.cursor/rules/frontend.mdc · 0 | Cursor rules | setuptestlint-formatstyle+7 | 99/100 | 3 days ago | |
| deifos/clipmira-subtitles.cursor/rules/frontend.mdc · 1 | Cursor rules | setuptestlint-formatstyle+7 | 99/100 | 3 days ago | |
| dodgecfr/combatfilms-webapp.cursor/rules/frontend.mdc · 0 | Cursor rules | setuptestlint-formatstyle+7 | 99/100 | 3 days ago | |
| langflow-ai/langflow.cursor/rules/docs_development.mdc · 153k | Cursor rules | setupbuildtestlint-format+7 | 97/100 | 3 days ago | |
| TechSquidTV/Hermes.cursor/rules/20-hermes-api-tests.mdc · 45 | Cursor rules | teststyletesting-strategysecurity+3 | 97/100 | 3 days ago |
