連線檔案

這是 cat 的主要目的。

cat file1 file2 file3 > file_all

cat 也可以類似地用於連線檔案作為管道的一部分,例如

cat file1 file2 file3 | grep foo