diffity-diff
nilbuild/diffity
Open an interactive diff viewer in your browser to visualize and comment on code changes.
What is diffity-diff?
Diffity-diff launches an in-browser diff viewer for inspecting git changes, comparing branches, or reviewing pull requests. Use it when you want a visual, interactive way to examine what changed and leave comments on specific lines.
- Launch a local diff viewer server accessible in your browser
- Display working tree changes, branch diffs, or GitHub PR diffs
- Reuse existing server instances for the same repository
- Enable inline commenting on specific lines of code
- Integrate with follow-up skills (/diffity-resolve, /diffity-review) for code review workflows
How to install diffity-diff
npx skills add https://github.com/nilbuild/diffity --skill diffity-diff- Git repository initialized in the current directory
- Node.js and npm installed (diffity will be installed globally if not present)
How to use diffity-diff
- 1.Run /diffity-diff with an optional git ref (e.g., main..feature) or GitHub PR URL, or omit the ref to see working tree changes
- 2.Wait for the skill to start the diff viewer server and open your browser
- 3.Review the changes visually in the browser interface
- 4.Leave comments on specific lines as needed
- 5.Run /diffity-resolve to address comments, or /diffity-review for an AI code review
Use cases
- Review your own changes before committing or pushing to a branch
- Compare two git refs (e.g., main..feature) to see what's different
- View a GitHub pull request diff locally in an interactive viewer
- Leave comments on specific lines, then resolve them with /diffity-resolve
- Get an AI code review of your changes via /diffity-review
- Developers reviewing their own code changes
- Teams conducting code reviews
- Anyone wanting a visual alternative to command-line diff tools
diffity-diff FAQ
The CLI automatically reuses the existing server instance and opens your browser to it, so you don't need to manage multiple processes.
Yes, pass a GitHub PR URL (e.g., https://github.com/owner/repo/pull/123) as the ref argument to view the PR diff.
Any valid git ref syntax: branch names, commit hashes, ranges (main..feature), relative refs (HEAD~3), or GitHub PR URLs.
After leaving comments in the browser, run /diffity-resolve to apply fixes based on the feedback.
Yes, run /diffity-review after opening the diff to get an AI-powered code review of your changes.
Full instructions (SKILL.md)
Source of truth, from nilbuild/diffity.
name: diffity-diff description: Open the diffity diff viewer in the browser to see your changes user-invocable: true
Diffity Diff Skill
You are opening the diffity diff viewer so the user can see their changes in the browser.
Arguments
ref(optional): Git ref to diff (e.g.main..feature,HEAD~3) or a GitHub PR URL (e.g.https://github.com/owner/repo/pull/123). Defaults to working tree changes.
Instructions
-
Check that
diffityis available: runwhich diffity. If not found, install it withnpm install -g diffity. -
Run
diffity <ref>(or justdiffityif no ref) using the Bash tool withrun_in_background: true:- The CLI handles everything: if an instance is already running for this repo it reuses it and opens the browser, otherwise it starts a new server and opens the browser.
- Do NOT use
&or--quiet— let the Bash tool handle backgrounding.
-
Wait 2 seconds, then run
diffity list --jsonto get the port. -
Tell the user diffity is running. Print the URL and keep it short — don't show session IDs, hashes, or other internals. Example:
Diffity is running at http://localhost:5391
When you're ready:
- Leave comments on the diff in your browser, then run /diffity-resolve to fix them
- Or run /diffity-review to get an AI code review
Related skills
More from nilbuild/diffity and the wider catalog.

diffity-learn
Learn any technical topic through interactive projects and guided tours.

diffity-resolve
Resolve code review comments by making requested fixes and changes.

diffity-resolve-tree
Resolve code review comments from diffity tree browser by making requested fixes

diffity-review
Review diffs and leave inline comments using diffity agent commands

diffity-tour
Create interactive guided code tours that walk through your codebase step-by-step in the browser.

diffity-tree
Browse and comment on repository files in an interactive web-based file tree.