cat is used to concatenate or write files, text or binary.
cat > list.txt
type into the terminal:
aaa bbb ccc
Press CTRL+D to stop inputting and save file.
This would have created the file list.txt.
cat list.txt
returns:
aaa bbb ccc
Create another file, named list2.txt, containing:
ddd
eee
cat list.txt list2.txt
returns:
aaa
bbb
ccc
ddd
eee
cat list.txt list2.txt > list3.txt
cat list3.txt
returns:
aaa
bbb
ccc
ddd
eee
cat >> list3.txt
enter:
fff ggg
Press CTRL+D to stop inputting and save file.
cat list3.txt
returns:
aaa
bbb
ccc
ddd
eee
fff
ggg
cat list.txt - list2.txt > list4.txt
enter:
hhh
Press CTRL+D to stop inputting and save file.
cat list4.txt
returns:
aaa
bbb
ccc
hhh
ddd
eee
NOTE: The hhh data is showing in the middle of the data from the 2 input files.
cat video.001 video.002 video.003 > vid.avi