plan
Create an implementation plan before writing code. Use for new features, architectural changes, or complex refactoring.
Review code for security, quality, and best practices. Use after writing code and before committing.
> /plugin marketplace add ab604/claude-code-r-skillsHow it fires
How this command gets triggered: by you, by Claude, or both.
/code-reviewContext preview
What this command does when you run it.
Review code for security, quality, and best practices. Use after writing code and before committing.
name: code-review description: Review code for security, quality, and best practices. Use after writing code and before committing.
Review uncommitted code changes for security vulnerabilities, code quality issues, and R best practices.
1. **Identify Changes** - `git diff --name-only HEAD` 2. **Review Each File** - Check against criteria below 3. **Generate Report** - Severity-rated findings 4. **Block or Approve** - Based on issue severity
| Level | Action | Examples | |-------|--------|----------| | **CRITICAL** | Must fix before commit | Hardcoded secrets, SQL injection | | **HIGH** | Should fix before commit | Missing error handling, no tests | | **MEDIUM** | Fix when possible | Style issues, minor refactoring | | **LOW** | Consider for improvement | Documentation, naming suggestions |
## Code Review: [files reviewed] ### CRITICAL Issues - **[file:line]** - [description] - Fix: [suggested fix] ### HIGH Issues - **[file:line]** - [description] ### MEDIUM Issues - **[file:line]** - [description] ### Suggestions - [improvement ideas] ## Verdict: APPROVED / NEEDS CHANGES
**Block commit if:**
**Approve with caution if:**
# Check for anti-patterns
- data %>% filter() # Use |> instead
- sapply(x, f) # Use map_*() instead
- group_by() |> ungroup() # Use .by instead
- by = c("a" = "b") # Use join_by() instead
# Check for good patterns
+ data |> filter() # Native pipe
+ map_dbl(x, f) # Type-stable
+ summarise(..., .by = group) # Per-operation grouping
+ inner_join(x, y, join_by()) # Modern join syntax/code-review
Review will automatically check all uncommitted changes.
A curated collection of Claude Code configurations for modern R use. These skills, rules, commands, and agents help Claude Code understand R best practices and generate idiomatic, high-quality R code.
Repo: ab604/claude-code-r-skills
Create an implementation plan before writing code. Use for new features, architectural changes, or complex refactoring.
Test-driven development workflow for R. Write tests first, then implement. Use for new features, bug fixes, and refactoring.
Run full R verification loop before committing. Checks build, lint, style, test coverage, and code quality.