Skip to main content

Pretty side-by-side diff

Project description


Pretty side-by-side diff.

Inspired by ydiff and icdiff.




pip install pdiff


brew install nkouevda/nkouevda/pdiff


usage: pdiff [<options>] [--] <old file> <new file>

Pretty side-by-side diff

optional arguments:
  -h, --help            show this help message and exit
  -b, --background, --no-background
                        highlight background instead of foreground (default: True)
  -l, --line-numbers, --no-line-numbers
                        show line number columns (default: True)
  -t <n>, --expand-tabs <n>
                        expand tabs to <n> spaces (default: 8)
  -s, --signs, --no-signs
                        show sign columns (default: True)
  -U <n>, --unified <n>
                        show <n> lines of context (default: 3)
  -v, --version         show program's version number and exit
  -w <n>, --width <n>   fit output to <n> columns (default: autodetect)


Configure a pdiff difftool, and add some aliases to your liking, e.g.:

[difftool "pdiff"]
	cmd = "pdiff -- \"$LOCAL\" \"$REMOTE\" | less --Raw-control-chars"

	dfp = difftool --tool=pdiff
	dfpc = difftool --tool=pdiff --cached


MIT License

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for pdiff, version 1.1.2
Filename, size File type Python version Upload date Hashes
Filename, size pdiff-1.1.2-py3-none-any.whl (7.5 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size pdiff-1.1.2.tar.gz (6.2 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page