PocketPatch is a local, mobile-friendly diff review tool for uncommitted code changes. It is built for reviewing agent-generated work from a phone without creating a pull request first.
Run it from a repository, open the review URL on your phone, leave comments on changed lines, then read or resolve those comments from the CLI.
Install the PocketPatch agent skill with the skills CLI:
npx skills add kadencartwright/pocketpatch --skill pocketpatchInstall it globally for all projects:
npx skills add kadencartwright/pocketpatch --skill pocketpatch -gAfter installation, ask your agent to use PocketPatch for review. The skill teaches agents to register the current repository, share the review URL, read comments, and resolve handled feedback.
npx pocketpatch registerregister starts the local PocketPatch daemon if needed, registers the current
working directory, and prints a review URL.
Open that URL in a browser. The review page shows the current uncommitted diff for the registered project.
After reviewing:
npx pocketpatch commentsResolve a comment when it has been handled:
npx pocketpatch comments resolve 1- Node.js 20 or newer
- Git
- A way for your phone to reach the machine running PocketPatch
PocketPatch works especially well over Tailscale. Configure the daemon to bind to your Tailscale IP and the review URL will be reachable from other devices on your tailnet.
List local network addresses:
npx pocketpatch config addressesSet the bind address to your Tailscale IP:
npx pocketpatch config set-bind-address 100.x.y.zRegister your project again:
npx pocketpatch registerBy default, PocketPatch uses port 3217.
| Command | Description |
|---|---|
pocketpatch register [path] |
Register a project and print its review URL. Starts the daemon if needed. |
pocketpatch comments |
Print unresolved comments for the current registered project. |
pocketpatch comments --show-resolved |
Include resolved comments. |
pocketpatch comments --project <id> |
Print comments for a specific project. |
pocketpatch comments resolve <id> |
Mark a comment resolved. |
pocketpatch config addresses |
List local addresses that can be used for daemon binding. |
pocketpatch config show |
Print the active config file path and config JSON. |
pocketpatch config set-bind-address <ip> |
Persist the daemon bind address. |
pocketpatch daemon plan |
Print the endpoints the daemon will bind. |
pocketpatch daemon start |
Start the daemon in the foreground for debugging. |
PocketPatch reviews the current uncommitted diff. Comments are attached to changed lines and hidden when their file or anchor line is no longer present in the current diff.
The CLI prints unresolved comments by default so an agent can retrieve feedback, make changes, and resolve items as it works.
PocketPatch stores user-scoped config and state using XDG-style paths:
- Config:
$XDG_CONFIG_HOME/pocketpatch/config.json, or~/.config/pocketpatch/config.json - State database:
$XDG_STATE_HOME/pocketpatch/pocketpatch.db, or~/.local/state/pocketpatch/pocketpatch.db - Cache:
$XDG_CACHE_HOME/pocketpatch, or~/.cache/pocketpatch
The default config is:
{
"version": 1,
"network": {
"bindAddress": null,
"port": 3217
}
}Install dependencies:
pnpm installRun the app and daemon while iterating:
pnpm run devRun checks:
pnpm test
pnpm typecheck
pnpm lint
pnpm fallowBuild the CLI package and bundled web app:
pnpm --filter pocketpatch build