On Tue, 2002-06-25 at 10:55, Mark G. Spencer wrote:
> So .. Is there another MD5 utility with more flexibility?  I basically
> need to MD5 every file individually in a large directory tree with the
> output redirected to a text file showing the path, filename, and hash
of
> every file in that directory tree.

Learn about your tools. The philosophy in Unix is "simple tools combine
to give infinite flexibility".

The 'find' command should help you do what you want. Here's an example: 

find FOODIR -type f -exec md5sum '{}' ';' > md5sums-for-FOODIR

Which searches for all files under FOODIR and runs md5sum on each one,
piping the output of md5sum into a file called md5sums-for-FOODIR. This
file is in the format accepted by md5sum -c, so you can now easily check
FOODIR against the stored sums by doing:

md5sum -c md5sums-for-FOODIR

Have fun,
-Jim

Reply via email to