How this skill is triggered — by the user, by Claude, or both
Slash command
/nrf-library:code-reviewThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
1. **Files to review** (optional) — specific file paths to review; defaults to all files changed on the current branch vs `main`
maingh pr diff <url> to get the changed files instead of git diff.ai/rules/index.md and all files it links to, to load the project coding standards.gh pr diff <url> --name-only to get the changed files, and gh pr diff <url> to read the diff content.git diff main...HEAD --name-only to list all files changed on the current branch vs main.git diff --name-only HEAD (unstaged changes) and git diff --name-only --cached (staged changes), and combine the results.*.test.js, *.acceptance.test.js).For each file with findings:
### path/to/file.js
**Blockers**
- Line 42: `logger.error('message')` — first param must be an error instance, not a string
**Suggestions**
- Line 10: function `doThing` has 4 primitive params — consider using an object param
If a file has no findings, omit it from the report.
End with a one-line summary: total files reviewed, total blockers, total suggestions.
If a GitHub PR URL was provided, after outputting the report ask the user whether they want to post it as a comment on the PR. If they confirm, post the report using gh pr comment <url> --body "<report>".
Note:
ghmay only be used forgh pr comment. Do not use any otherghsubcommands (e.g.gh pr diff,gh pr create,gh issue).
Return only the structured findings report and the one-line summary to the main agent. Do not include preamble, tool call narration, or explanation of steps taken.
Guides creation, editing, and verification of skills for AI coding agents using test-driven development with subagent scenarios. Use when authoring or debugging skills.
npx claudepluginhub defra/nrf-library