How can I collect several files into a single file?
I tried GZip, but could only get it to create separate files.
It does not have to be compressed.
Answer
Simply use cat
:
cat file1 file2 file3 > output
If you want to combine all files in the current directory:
cat * > output
If you need to adjust the order of the files in the output, use echo first to get all filenames:
echo *
Then supply them in the desired order to cat
.
No comments:
Post a Comment