'cmptree' utility
November 23, 2012 —
BarryK
'cmp' is a binary-file-compare utility, that is in all pups. We use the full version from the 'diffutils' package, rather than the Busybox version.
'cmptree' is a Bash script, created by Ives Aerts, described here:
http://www.drdobbs.com/the-shell-corner-cmptree/199103123
'cmptree' uses 'cmp', and recursively goes through comparing two directories.
I have used this to create a Service Pack for Precise Puppy, and it worked very nicely.
I had to process the output a little bit to screen out some stuff, where 'out1' is the output create by cmptree:
# cat out1 | grep -v -E '/dev/|root/\.packages' > out2
Of course, the 'diff' utility can be made to do something similar, but it is nice to have a specific tool.
This is a very handy utility, so I have added it to Woof:
http://bkhome.org/fossil/woof2.cgi/info/2ef521dafe
Tags: woof