What You Get
A Cursor rule that teaches the AI agent how to use the full CodeAnt CLI. Once installed, you can ask Cursor to:- Review your code changes for bugs, security issues, and code quality
- Fetch unaddressed PR review comments and fix them automatically
- List and explore pull requests in the repository
- Search across review comments
- Scan for exposed secrets before committing
- Run security and static analysis
- Fix issues found by CodeAnt automatically
Prerequisites
- Cursor installed (download)
- CodeAnt CLI installed and authenticated:
- SCM token configured (required for PR features):
Installation
Option 1: Clone from Skills Repo (Recommended)
Option 2: Create Manually
Create.cursor/rules/codeant.mdc — see the full rule content in the skills repository.
Usage
Review Code Changes
Ask Cursor to review your work after implementing a feature:- Implement the feature
- Run
codeant review --uncommitted - Parse the findings
- Fix each issue
- Re-run the review to verify
Auto-Fix PR Comments
The most powerful workflow — fix all unaddressed review comments on a PR:- Run
codeant pr comments --pr-number 42 --codeant-generated true --addressed false - Parse the JSON to get file paths, line ranges, descriptions, and suggested fixes
- Apply suggested fixes where available
- Implement fixes for issues without suggestions
- Run
codeant review --uncommittedto verify
Explore Pull Requests
Search Review Comments
Scan for Secrets
Security Analysis
Static Analysis with Auto-Fix
Example Workflows
Full PR Auto-Fix Loop
Implement → Review → Fix → Ship
Explore → Investigate → Fix
How It Works
The.cursor/rules/codeant.mdc file is a Cursor Rule that is automatically loaded into every AI conversation in your project. It teaches the Cursor agent:
- All available CodeAnt CLI commands (review, PR management, scanning)
- The auto-fix workflow for PR comments
- When to use each command
- How to parse JSON and terminal output
- How to handle the review-fix-verify cycle
alwaysApply: true, so the agent always knows about CodeAnt — you don’t need to explicitly reference it.
Troubleshooting
“codeant: command not found” Ensure the CLI is installed globally and accessible from Cursor’s terminal:- Verify
.cursor/rules/codeant.mdcexists and hasalwaysApply: truein frontmatter - Restart Cursor after adding the rule
- Be explicit: “Use CodeAnt to review my changes”