branch-review-canvas
Skill1 starsChanged 4 months agoMITView on GitHub
Render a supplied branch or commit diff, or the current branch diff against main, as a Cursor Canvas that groups changes by reviewer importance, separates boilerplate from core logic, and highlights tricky or unexpected code. Use when reviewing a branch, commit, local diff, or when the user asks for a branch review canvas, diff walkthrough, or change-set overview.
In this repository6 other files it gives its agents.
- AGENTS.mdAGENTS.md
- bktSkill
- grug-reviewSkill
- pairSkill
- terraformSkill
- walkthroughSkill
The file
We split this skill into the rules it gives an agent
7 rules. About 0 are common, 5 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈5
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 17
Read ~/.cursor/skills-cursor/canvas/SKILL.md first.
- Very specific: line 21
Use @branch, @commit, or another explicit Cursor diff reference when supplied — do not re-discover range with git.
- Distinctive: line 23
If PR metadata exists, prefer the PR's base branch.
- Distinctive: line 24
If the base is still unclear, ask once — do not guess silently.
- Distinctive: line 28
When git is needed (no explicit diff reference):
- Distinctive: line 34
If the resolved base ref is missing or diff commands fail, stop and report the blocker.
- Distinctive: line 38
Not alphabetical or tree order:
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Branch review canvas
Build a canvas that presents the requested diff reorganized for reviewer comprehension, not in file-tree order. For a prose teaching walkthrough, use pr-walkthrough instead.
Prerequisites
Read ~/.cursor/skills-cursor/canvas/SKILL.md first. Component and hook shapes: ~/.cursor/skills-cursor/canvas/sdk/index.d.ts and siblings — read, do not guess.
Comparison base
- Use
@branch,@commit, or another explicit Cursor diff reference when supplied — do not re-discover range with git. - Else use the checked-out branch against
main; if absent, trymaster. - If PR metadata exists, prefer the PR's base branch.
- If the base is still unclear, ask once — do not guess silently.
Gather the diff
When git is needed (no explicit diff reference):
git branch --show-current,git status --short --branchgit diff --stat <base>...HEADandgit diff --find-renames <base>...HEADfor committed workgit diff --statandgit diff --find-renamesfor uncommitted edits that belong in the review
If the resolved base ref is missing or diff commands fail, stop and report the blocker. If an explicit reference lacks enough content, ask — do not guess.
Group changes for comprehension
Not alphabetical or tree order:
- Core logic: behavior, algorithms, state, API surface — full diffs with context.
- Wiring and integration: routes, DI, config — condensed enough to verify.
- Boilerplate and mechanical: imports, renames, generated code — file list + stats unless a hunk matters.
Lead with core logic.
Distill and call out
- Pseudocode beside dense core hunks (state machines, retries, multi-step transforms) — not for straightforward edits.
- Concrete input walkthrough (old vs new path) only when behavior is hard to predict from the hunk.
- Tags (
Subtle,Breaking,Race condition,Perf) + one sentence only for genuinely tricky items.
Tone
Reviewer-facing, terse (one or two sentences): why, cross-file interactions, what the diff hides, whether local edits are in scope.
Be creative
Sections above are a floor. Pick canvas components (charts, tables, diff views, DAG, cards) that fit this change — refactor vs bugfix vs feature may need different layouts.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

