From agent-workflows
Reviews uncommitted changes, file paths/globs, or GitHub PRs for security issues, code quality problems, and performance best practices, reporting findings by severity using git diff and gh pr diff.
npx claudepluginhub sjarmak/agent-workflowsThis skill uses the workspace's default tool permissions.
Comprehensive code review of uncommitted or recently committed changes. Reviews for security, quality, and maintainability, then reports findings by severity.
Mandates invoking relevant skills via tools before any response in coding sessions. Covers access, priorities, and adaptations for Claude Code, Copilot CLI, Gemini CLI.
Share bugs, ideas, or general feedback.
Comprehensive code review of uncommitted or recently committed changes. Reviews for security, quality, and maintainability, then reports findings by severity.
$ARGUMENTS — format: [file path | glob pattern | PR number | blank]
gh pr diff.Extract:
git diff --staged and git diff to capture all changes.gh pr diff <number> to get the full diff.git log --oneline -5 and offer to review the last commit.For each changed file, also read surrounding code — don't review changes in isolation.
Launch 3 parallel review agents, each focused on a different severity tier:
Review ONLY for security issues. Flag these if found:
- Hardcoded credentials (API keys, passwords, tokens, connection strings)
- SQL injection (string concatenation in queries)
- XSS vulnerabilities (unescaped user input in HTML/JSX)
- Path traversal (user-controlled file paths without sanitization)
- CSRF vulnerabilities (state-changing endpoints without protection)
- Authentication bypasses (missing auth checks on protected routes)
- Exposed secrets in logs (logging tokens, passwords, PII)
- Insecure deserialization or command injection
For each issue, report: file path, line number, what's wrong, and how to fix it.
Only report issues you are >80% confident are real problems, not pre-existing issues.
Review for code quality issues. Flag these if found:
- Functions over 50 lines
- Files over 800 lines
- Nesting depth over 4 levels
- Missing error handling (unhandled rejections, empty catch blocks)
- Mutation patterns where immutable operations should be used
- Debug logging left in (console.log, print statements)
- Dead code (commented-out code, unused imports, unreachable branches)
- Missing tests for new code paths
Consolidate similar issues (e.g., "5 functions missing error handling" not 5 separate findings).
Only report issues in changed code. Skip stylistic preferences unless they violate project conventions.
Review for performance and best practice issues:
- Inefficient algorithms (O(n^2) when O(n) or O(n log n) is possible)
- Missing caching for repeated expensive computations
- Large bundle imports when tree-shakeable alternatives exist
- N+1 query patterns
- Unbounded queries without LIMIT
- Missing timeouts on external calls
- TODO/FIXME without issue references
- Magic numbers without explanation
Only flag issues that materially affect the code. Skip minor nitpicks.
For each finding from Phase 2, assess confidence (0-100):
Filter out findings below 75 confidence.
Present findings grouped by severity:
[CRITICAL] Description
File: path/to/file.ts:42
Issue: What's wrong and why it matters
Fix: Specific fix recommendation
[HIGH] Description
File: path/to/file.ts:88
Issue: What's wrong
Fix: How to fix it
End with a summary table:
## Review Summary
| Severity | Count | Status |
|----------|-------|--------|
| CRITICAL | 0 | pass |
| HIGH | 2 | warn |
| MEDIUM | 1 | info |
| LOW | 0 | — |
Verdict: APPROVE / WARNING / BLOCK
/focus, this is the review phase between simplify and close.