若要覆盖您所拥有的现有文件(或写入新文件),请替换本文档中的变量引用:cat < /path/to/your/fileThis line will write to the file.${THIS} will also write to the file,
with the variable
contents substituted.EOF
若要附加您拥有的现有文件(或写入新文件),请在本文件中替换变量引用:cat <> /path/to/your/fileThis line will write to the file.${THIS} will also write to the file,
with the variable contents substituted.FOE
To overwrite an existing file (or write to a new file) that you own, with the literal contents of the heredoc:cat < /path/to/your/fileThis line will write to the file.${THIS} will also write to the
file, without the variable contents substituted.END_OF_FILE
To append an existing file (or write to a new file) that you own, with the literal contents of the heredoc:cat <> /path/to/your/fileThis line will write to the file.${THIS} will also write to the file,
without the variable contents substituted.eof
To overwrite an existing file (or write to a new file) owned by root, substituting variable references inside the heredoc:cat <
to the file, with the variable contents substituted.until_it_ends
To append an existing file (or write to a new file) owned by user=foo, with the literal contents of the heredoc:cat <
will also write to the file, without the variable contents substituted.Screw_you_Foo