Beautify Git Diffs

İbrahim Gündüz
2 min readMay 23, 2022

Though Git colorizes the diff outputs, it’s still not easy to recognize exactly what’s changed in a line. Please have a look at the following screenshot:

Though there are only a few characters of changes, it appears like the whole line is removed and added in a different shape.

Anyways... If you wanna make a better git diff view, you can use some external tools like https://github.com/dandavison/delta Git-delta creates a really awesome view like the following one which is easy to read.

How To Install Git-Delta

Mac

You can use the following homebrew formula to install git-delta

$ brew install git-delta

Ubuntu

$ sudo dpkg -i <the package name>.deb

Other Operating Systems:

Please visit https://dandavison.github.io/delta/installation.html

How To Configure Git-Delta

You can configure it simply like the following one or, review more options from https://dandavison.github.io/delta/configuration.html

$ git config --global core.pager delta$ git config --global interactive.diffFilter ‘delta --color-only’$ git config --global diff.colorMoved default

--

--