Archives for September 2007

Combining (“Feathering”) Linux Output

Regarding an earlier article entitled, Using MD5SUM to Validate the Integrity of (Downloaded) Files, one reader, by the name of Faheem, wanted to know how to calculate the checksum for multiple files and show those checksums correlated together with other properties of those files. In other words, he wants to be able to issue the “ls -l” command to list all of the properties of all of the files in the current folder, and the do the same with the md5sum command, except that he wants the checksums to be side-by-side with the ls -l results, not following it.

For example, say that the current folder contains two files, Great_Gatsby.txt and Huck_Finn.asc.

We could issue the following compound-command:

ls -l; md5sum *.*

and the output would be something like this:

-rwx------+ Great_Gatsby.txt
-rwx------+ Huck_Finn.asc
4823c9398e405df4db0320312c91d365 *Great_Gatsby.txt
adb3ae8c055879e65b386b57f016055b *Huck_Finn.asc

But, what we need is it for the output to be more like this:

-rwx------+ Great_Gatsby.txt 4823c9398e405df4db0320312c91d365
-rwx------+ Huck_Finn.asc    adb3ae8c055879e65b386b57f016055b

Continue Reading »

© 2006-2007 Maxim Software Corp.  All rights reserved.