An agent skill (Claude Code, Codex, and anything else that reads SKILL.md) that turns your whole branch diff into one self-contained, mobile-first, GitHub-style review page. You tap lines and leave comments, then press one button to copy all of them in a format your coding agent can act on straight away.
- One HTML file per run. All CSS and JS are inline, there are no network requests, and no dependencies beyond Python 3 and git. The template is about 40 KB.
- The whole branch. It diffs the merge-base with your base branch against the working tree, so you see commits, staged, unstaged and untracked files.
- Built for phones. It uses a single line-number gutter, wraps lines, keeps file headers sticky, puts thumb-sized actions in a bottom dock, respects safe areas, and follows dark mode automatically.
- GitHub-like. You get unified diffs, intra-line change highlights, light syntax highlighting, "Viewed" checkboxes, file comments, and a file list.
- Fast. A 300-file, ~48k-changed-line diff (a 10 MB page) is interactive in about 0.6 s on an emulated Pixel with 4× CPU throttling. Files render lazily, and lockfiles and huge files are collapsed behind "Load diff" (by line count, size, or line length).
- Nothing gets lost. Comments autosave in
localStoragefor each diff, so a reload or a killed mobile tab keeps them.
# Claude Code
git clone https://github.com/DNGriffin/codereview-site ~/.claude/skills/codereview-site
# Codex
git clone https://github.com/DNGriffin/codereview-site ~/.codex/skills/codereview-siteAsk your agent something like "make me a review page for this branch" or "I want to review the diff on my phone" (in Claude Code you can also type /codereview-site). The agent runs:
python3 ~/.claude/skills/codereview-site/scripts/codereview.py [--open] [--serve]| flag | |
|---|---|
--open |
open it in your default browser |
--serve |
background server for your phone: serves only that file at a secret URL, gzipped, stops on its own after --minutes (default 120). It prints LAN URLs, which also work over Tailscale or another VPN. It never tunnels to the public internet, and the skill tells agents not to either unless you ask. |
--base <ref> |
base branch (auto-detects origin/HEAD, origin/main, origin/master, main, master, …) |
--committed |
only committed changes; --no-untracked skips new untracked files |
-U <n> / -w |
context lines / ignore whitespace |
-o <file> |
output path (default: $TMPDIR/codereview/<repo>-<branch>-<time>.html) |
[paths…] |
limit the diff to these paths |
On the page, tap a line to select it and tap a second line to extend the selection to a range (shift-click works on desktop). Then press Comment. The 💬 button on a file header comments on the whole file, and there's an "Overall feedback" box at the bottom. Press Copy all and paste into your agent:
Please address these code review comments on branch `feature/x` (diff vs `main`, repo `app`). Line numbers refer to the new version of each file unless marked deleted.
Overall:
Also add tests for avg().
1. `src/app.js:12`
```diff
+const config = { retries: 5, timeout: 1000, url: 'http://example.com' };
```
Read retries from an env var instead of hard-coding 5.
2. `to_delete.txt` deleted line 2 (old numbering)
```diff
-bye
```
Is anything still importing this?
Desktop shortcuts: c or Enter comments on the current selection, ⌘/Ctrl+Enter saves, Esc cancels.
When the page is opened over plain-http LAN, where the Clipboard API is blocked, copying falls back to execCommand. If that is blocked too, a select-all text box appears.
python3 tests/gen_test.py # generator: git edge cases, hostile git config, --serve
bash tests/make_fixture.sh /tmp/fx && (cd /tmp/fx && python3 "$OLDPWD/scripts/codereview.py" -o /tmp/fx.html)
npm i playwright && npx playwright install webkit chromium
node tests/ui.test.mjs /tmp/fx.html [shots/] # 64 e2e checks: desktop Chrome, iPhone WebKit (file:// + LAN, dark), Pixel, iPhone SE
node tests/tokenizer.test.mjs # highlighter correctness + linear time on hostile lines
node tests/perf.mjs /path/to/huge.html # phone-throttled load / tap / jump timingsThe fixture covers renames, binaries, mode changes, symlink→file type changes, __proto__-style filenames, CRLF, "no newline at EOF", lines starting with --/++, unicode and space paths, </script> injection, big files, lockfiles, and staged, unstaged and untracked changes.
MIT

