Results 1 to 3 of 3
I have this command (line):
Code:
tail -52 | find "/path/" -name "*.csv"
Instead of printing the contents of each file, the command prints the location of each file.
What ...
- 10-22-2010 #1Just Joined!
- Join Date
- Oct 2010
- Posts
- 9
Printing Content of File
I have this command (line):
Instead of printing the contents of each file, the command prints the location of each file.Code:tail -52 | find "/path/" -name "*.csv"
What am I doing wrong?
- 10-27-2010 #2Just Joined!
- Join Date
- Jul 2008
- Posts
- 5
Try using cat with the backtick operator, e.g.:
The backtick operator causes the enclosed string to be executed. Then that string is replaced with the output of the command, and the rest of the command line is executed with the replacement. So cat receives a list of file names as arguments, and it prints the contents of each listed file.Code:cat `tail -52 | find "/path/" -name "*.csv"`
- 10-27-2010 #3Just Joined!
- Join Date
- Oct 2010
- Posts
- 9
Thanks. It worked
. (Well the reverse way: find "/path/" -name "*.csv"`| cat tail -52)


Reply With Quote