I’ve tried a lot of tools for comparing files and directories, but all of them fell short somehow. I wanted a tool that:
- Works everywhere. Linux, Mac, Windows. In a terminal window.
- Compares directories recursively.
- Does two-way and three-way comparisons.
- Operates as a Git difftool and mergetool.
- Edits files it’s comparing.
If I were a Vim user, I think DirDiff would be great! But my fingers speak Emacs. Generally Emacs’s Ediff is excellent, but I find its directory comparison awkward. It forces you to visit every subdirectory to find the differing needle in the haystack.
My own Emacs dircmp-mode uses Ediff for file comparison, and Rsync for directory comparison. It displays all the differences between a pair of directories in a single buffer and lets you visit any differing file pair in Ediff. I’m using git-diffall to invoke dircmp-mode as an all purpose Git difftool, and Ediff as my Git mergetool.
It’s working well for me. If you try it, I’d love to hear your feedback, good or bad.