coderabbit-local-dev-loop
Configure CodeRabbit CLI for local pre-commit code reviews and fast iteration. Use when setting up local development with CodeRabbit CLI reviews, integrating AI review into your commit workflow, or testing config changes. Trigger with phrases like "coderabbit dev setup", "coderabbit local development", "coderabbit CLI workflow", "coderabbit pre-commit review".
Best use case
coderabbit-local-dev-loop is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Configure CodeRabbit CLI for local pre-commit code reviews and fast iteration. Use when setting up local development with CodeRabbit CLI reviews, integrating AI review into your commit workflow, or testing config changes. Trigger with phrases like "coderabbit dev setup", "coderabbit local development", "coderabbit CLI workflow", "coderabbit pre-commit review".
Teams using coderabbit-local-dev-loop should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/coderabbit-local-dev-loop/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How coderabbit-local-dev-loop Compares
| Feature / Agent | coderabbit-local-dev-loop | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Configure CodeRabbit CLI for local pre-commit code reviews and fast iteration. Use when setting up local development with CodeRabbit CLI reviews, integrating AI review into your commit workflow, or testing config changes. Trigger with phrases like "coderabbit dev setup", "coderabbit local development", "coderabbit CLI workflow", "coderabbit pre-commit review".
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
Related Guides
AI Agents for Coding
Browse AI agent skills for coding, debugging, testing, refactoring, code review, and developer workflows across Claude, Cursor, and Codex.
Cursor vs Codex for AI Workflows
Compare Cursor and Codex for AI coding workflows, repository assistance, debugging, refactoring, and reusable developer skills.
Best AI Skills for Claude
Explore the best AI skills for Claude and Claude Code across coding, research, workflow automation, documentation, and agent operations.
SKILL.md Source
# CodeRabbit Local Dev Loop
## Overview
Use CodeRabbit CLI to review code locally before opening a PR. The CLI provides the same AI-powered review as the GitHub App but runs in your terminal against staged or unstaged changes. This creates a multi-layered review process: local CLI review before commit, then automated PR review after push.
## Prerequisites
- CodeRabbit CLI installed (`curl -fsSL https://cli.coderabbit.ai/install.sh | sh`)
- Git repository with `.coderabbit.yaml` configuration
- CodeRabbit account (CLI uses credits: $0.25 per file reviewed)
## Instructions
### Step 1: Install and Verify CLI
```bash
set -euo pipefail
# Install CodeRabbit CLI
curl -fsSL https://cli.coderabbit.ai/install.sh | sh
# Verify installation
cr --version
# Authenticate (opens browser for OAuth)
cr auth login
```
### Step 2: Local Review Workflow
```bash
set -euo pipefail
# Review all staged changes (most common workflow)
git add -A
cr review
# Review specific files only
cr review src/api/routes.ts src/middleware/auth.ts
# Interactive mode: ask follow-up questions about review feedback
cr review --interactive
# Plain output mode (pipe to other tools or AI agents)
cr review --prompt-only
```
### Step 3: Git Hook Integration
```bash
#!/bin/bash
# .git/hooks/pre-push (make executable: chmod +x .git/hooks/pre-push)
set -euo pipefail
echo "Running CodeRabbit pre-push review..."
# Get list of changed files vs remote
CHANGED_FILES=$(git diff --name-only @{push}.. 2>/dev/null || git diff --name-only HEAD~1)
if [ -n "$CHANGED_FILES" ]; then
echo "$CHANGED_FILES" | xargs cr review
# Non-blocking: show review but don't prevent push
# To make blocking, check exit code:
# echo "$CHANGED_FILES" | xargs cr review || {
# echo "CodeRabbit found issues. Push anyway? (y/n)"
# read -r response
# [ "$response" != "y" ] && exit 1
# }
fi
```
### Step 4: Configuration for Local Development
```yaml
# .coderabbit.yaml - Settings that affect both CLI and PR reviews
language: "en-US"
reviews:
profile: "assertive"
path_instructions:
- path: "src/**"
instructions: "Check for proper error handling and type safety."
- path: "tests/**"
instructions: "Verify edge cases and assertion completeness."
path_filters:
- "!**/*.lock"
- "!dist/**"
- "!**/*.generated.*"
auto_review:
enabled: true
drafts: false
chat:
auto_reply: true
```
### Step 5: IDE Integration Pattern
```json
// .vscode/tasks.json - Run CodeRabbit review from VS Code
{
"version": "2.0.0",
"tasks": [
{
"label": "CodeRabbit: Review Current File",
"type": "shell",
"command": "cr review ${file}",
"presentation": { "reveal": "always", "panel": "shared" },
"problemMatcher": []
},
{
"label": "CodeRabbit: Review Staged Changes",
"type": "shell",
"command": "cr review",
"presentation": { "reveal": "always", "panel": "shared" },
"problemMatcher": []
}
]
}
```
## Two-Layer Review Strategy
```
Developer writes code
│
▼
┌──────────────────┐
│ cr review (local) │ ← Layer 1: Fast feedback before commit
│ Fix obvious issues│
└────────┬─────────┘
│
▼
git commit + push
│
▼
┌──────────────────┐
│ CodeRabbit App │ ← Layer 2: Full context review on PR
│ (automated PR │
│ review) │
└──────────────────┘
```
## Output
- CodeRabbit CLI installed and authenticated
- Pre-push git hook for automated local reviews
- VS Code task integration for on-demand reviews
- Two-layer review workflow (local + PR)
## Error Handling
| Issue | Cause | Solution |
|-------|-------|----------|
| `cr: command not found` | CLI not in PATH | Re-run install script or add to PATH |
| Auth token expired | Session timeout | Run `cr auth login` again |
| "No credits remaining" | Usage-based billing exhausted | Purchase credits at app.coderabbit.ai |
| Review hangs on large file | File too large for AI context | Review specific files instead of all |
| Empty review output | No changed files detected | Stage changes with `git add` first |
## Resources
- [CodeRabbit CLI Documentation](https://docs.coderabbit.ai/cli)
- [CLI Blog Announcement](https://www.coderabbit.ai/blog/coderabbit-cli-free-ai-code-reviews-in-your-cli)
- [VS Code IDE Extension](https://www.coderabbit.ai/ide)
## Next Steps
See `coderabbit-sdk-patterns` for PR interaction automation patterns.Related Skills
exa-local-dev-loop
Configure Exa local development with hot reload, testing, and mock responses. Use when setting up a development environment, writing tests against Exa, or establishing a fast iteration cycle. Trigger with phrases like "exa dev setup", "exa local development", "exa test setup", "develop with exa", "mock exa".
evernote-local-dev-loop
Set up efficient local development workflow for Evernote integrations. Use when configuring dev environment, setting up sandbox testing, or optimizing development iteration speed. Trigger with phrases like "evernote dev setup", "evernote local development", "evernote sandbox", "test evernote locally".
elevenlabs-local-dev-loop
Configure local ElevenLabs development with mocking, hot reload, and audio testing. Use when setting up a dev environment for TTS/voice projects, configuring test workflows, or building a fast iteration cycle with ElevenLabs audio. Trigger: "elevenlabs dev setup", "elevenlabs local development", "elevenlabs dev environment", "develop with elevenlabs", "test elevenlabs locally".
documenso-local-dev-loop
Set up local development environment and testing workflow for Documenso. Use when configuring dev environment, setting up test workflows, or establishing rapid iteration patterns with Documenso. Trigger with phrases like "documenso local dev", "documenso development", "test documenso locally", "documenso dev environment".
deepgram-local-dev-loop
Configure Deepgram local development workflow with testing and mocks. Use when setting up development environment, configuring test fixtures, or establishing rapid iteration patterns for Deepgram integration. Trigger: "deepgram local dev", "deepgram development setup", "deepgram test environment", "deepgram dev workflow", "deepgram mock".
databricks-local-dev-loop
Configure Databricks local development with Databricks Connect, Asset Bundles, and IDE. Use when setting up a local dev environment, configuring test workflows, or establishing a fast iteration cycle with Databricks. Trigger with phrases like "databricks dev setup", "databricks local", "databricks IDE", "develop with databricks", "databricks connect".
customerio-local-dev-loop
Configure Customer.io local development workflow. Use when setting up local testing, dev/staging isolation, or mocking Customer.io for unit tests. Trigger: "customer.io local dev", "test customer.io locally", "customer.io dev environment", "customer.io sandbox", "mock customer.io".
cursor-local-dev-loop
Optimize daily development workflow with Cursor IDE using Chat, Composer, Tab, and Git integration. Triggers on "cursor workflow", "cursor development loop", "cursor productivity", "cursor daily workflow", "cursor dev flow".
coreweave-local-dev-loop
Set up local development workflow for CoreWeave GPU deployments. Use when building containers locally, testing YAML manifests, or iterating on model serving configurations before deploying. Trigger with phrases like "coreweave dev setup", "coreweave local testing", "develop for coreweave", "coreweave container build".
cohere-local-dev-loop
Configure Cohere local development with mocking, testing, and hot reload. Use when setting up a development environment, configuring test workflows, or establishing a fast iteration cycle with Cohere API v2. Trigger with phrases like "cohere dev setup", "cohere local development", "cohere dev environment", "develop with cohere", "mock cohere".
coderabbit-webhooks-events
Implement CodeRabbit webhook signature validation and event handling. Use when setting up webhook endpoints, implementing signature verification, or handling CodeRabbit event notifications securely. Trigger with phrases like "coderabbit webhook", "coderabbit events", "coderabbit webhook signature", "handle coderabbit events", "coderabbit notifications".
coderabbit-upgrade-migration
Update CodeRabbit configuration for new features, migrate between plans, and adopt new capabilities. Use when CodeRabbit releases new features, upgrading from Free to Pro plan, or updating .coderabbit.yaml schema for new options. Trigger with phrases like "upgrade coderabbit", "coderabbit new features", "update coderabbit config", "coderabbit plan upgrade", "coderabbit changelog".