Hi all,
can any one help me out in this:::
basically i need to list all the contents in all files in all directories (starting from root and then onwards)...i will get the session saved in a file (just a secure CRT, etc)
seems to be a simple one.
if anyone can come forward, its really appreciated.
If you need the names of each file to prepend to the content's file in the final output file, use the following code ( slower than the previous one ) :
find / -type f | while read files
do
echo "$files"; cat "$files"
done > outfile
You can use the file command on each file before displaying it. If the output of that command contains the word "text", display it, otherwise display an error like "so-and-so is a binary file".