Tuesday, October 26, 2010

Tool for Comparing Two Directories

I'm struggling with initrd patches to improve boot-speed and durability and have found myself needing to compare two directories.
For future reference, this command, specifically for initrd images, will do so.
diff -qr $DIR1 $DIR2 | grep -v modules | sed -e 's/ and / /g' -e 's/Files //g' -e 's/ differ//g' | xargs -L 1 diff

No comments:

Post a Comment