explaingit

aduskelebe/diffpilot

15ShellAudience · developerComplexity · 2/5ActiveSetup · easy

TLDR

Terminal side-by-side diff viewer with syntax highlighting for 50+ languages, git integration, vim-style keys, and HTML or Markdown export.

Mindmap

mindmap
  root((diffpilot))
    Inputs
      Two file paths
      Git staged changes
      Two git branches
    Outputs
      Side-by-side diff
      HTML or Markdown export
      Clipboard copy
    Use Cases
      Review staged changes
      Compare branches
      Export diff for PR notes
    Tech Stack
      Shell
      Node.js

Things people build with this

USE CASE 1

Compare two files side by side in a terminal with syntax colours

USE CASE 2

Inspect what is currently staged in git before committing

USE CASE 3

Compare two git branches and jump between changes with n and p

USE CASE 4

Export a diff to HTML or Markdown to paste into a PR description

Tech stack

ShellNode.js

Getting it running

Difficulty · easy Time to first run · 5min

The bundled scripts/ folder is unrelated to the diff tool and exists to farm GitHub achievement badges.

In plain English

diffpilot is a small command-line tool that shows the differences between two files. It is designed to run inside a terminal window, with no browser tab and no separate graphical app. The README describes it as a side-by-side viewer with syntax highlighting, which means the two files are placed in two columns and the code is coloured so it is easier to read. The tool supports a few common ways of asking for a diff. You can pass it two file paths directly, you can ask it to show what is currently staged in git, or you can point it at two git branches and have it compare them. There is also an option to ignore whitespace, which is useful when the only differences between two files are spaces or tabs. The feature list in the README mentions syntax colouring for more than 50 programming languages, line numbers with markers next to changed lines, keyboard shortcuts for moving around, copying a section of the diff to the clipboard, and exporting the result as HTML or Markdown. Movement keys follow a vim-like style, with j and k to scroll, n and p to jump between changes, and q to quit. The repository also ships a folder of shell scripts under scripts/ that are not part of the diff tool itself. The README labels them as helpers for unlocking GitHub profile achievements, with names like quickdraw, yolo, publicist, and pull-shark. A separate Node script tracks which achievements have been earned. These are bundled alongside the diff viewer but serve a different purpose.

Copy-paste prompts

Prompt 1
Install diffpilot and run it against two local files with syntax highlighting on
Prompt 2
Use diffpilot to view the currently staged git changes and export the result as Markdown
Prompt 3
Compare main and feature-x branches in diffpilot while ignoring whitespace differences
Prompt 4
List the vim-style keyboard shortcuts in diffpilot for scrolling and jumping between hunks
Prompt 5
Walk me through what the bundled scripts folder in diffpilot does and whether the achievement scripts are safe to skip
Open on GitHub → Explain another repo

Generated 2026-05-22 · Model: sonnet-4-6 · Verify against the repo before relying on details.