![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Merging of rows | ssachins | Shell Programming and Scripting | 24 | 01-06-2009 11:40 AM |
| Cut rows | obedkhan | HP-UX | 2 | 08-23-2006 10:36 AM |
| Finding different rows | dombi | Shell Programming and Scripting | 2 | 03-06-2006 05:01 PM |
| Difference between two rows | JimJim | Shell Programming and Scripting | 7 | 07-05-2005 08:52 AM |
| Concatenate 2 rows into 1 row | indianadoug | Shell Programming and Scripting | 4 | 03-11-2005 11:05 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Cat of rows
Hello, I'm starting from the scratch with Unix, and I was wondering if you could give me an answer for this problem...
I've got a column with different names of files, something like: ./file1 ./file2 ... Now, I would like to show the content of each file. The column with the names comes from a pipeline, but I think that doesn't matter in this case. Of course I know about "cat", but if I type "....commands wich generate the above column.... | cat " the result is just the same. Thanks in advance. P.D. I know it's easy, but I'm so noob ![]() Last edited by kalius88; 01-18-2009 at 12:25 PM.. |
|
||||
|
I am not actually sure what you are asking. I understand that you will have a column of file names.. are you just wanting to cat those files and display the output? Code:
echo -e "test2.txt\ntest.txt\ntest.txt.bak" | xargs cat The echo will output those few files, one on each line, and the results are piped to xargs ( man xargs ), and xargs executes cat on each of the files, displaying the results of each. |
![]() |
| Bookmarks |
| Tags |
| cat, column, file |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|