Reputation: 4271
I have a project with a lot of files under /app. There are also subfolders with files. How can I print(hard copy) these files all out without manually printing each one?
Note: Not the file names. I want to print(hard copy) the contents of all files under /app
Upvotes: 1
Views: 1882
Reputation: 369064
Use find
:
find /app
If you want print only directories, specify it with -type d
(-type f
to print files only):
find /app -type d
UPDATE
find /app -type f -print -exec cat {} \;
To get file hard copied, use lpr
command:
find /app -type f -print -exec lpr {} \;
Upvotes: 3