Vim Tips Wiki

Use this page to discuss script 102 DirDiff

  • Add constructive comments, bug reports, or discuss improvements (see the guideline).
  • Do not document the script here (the author should do that on
  • This page may be out of date: check the script's page above, and its release notes.


Set LC_ALL=C before starting vim, otherwise the diff view for diffing files won't open.


Is there any easy way to set up this vim script to run with a config file or in a script so I can easily compare dir1 vs dir2, and dir3 vs dir4, dir5 vs dir6 without having to type all of them every time. ie I have to make modifications to config files across a system on a dev system, and I want to take those changes to qual and recompare them but they are not just in 1 directory with a single root they are like 6 directories I need to compare, frequently.



[ ! -d "$1" ] && exit 1
[ ! -d "$2" ] && exit 2
LANG=C vimdiff -c "DirDiff \"$1\" \"$2\""