以下の例では、todel.txt ファイルに $a=b という行があるはずでした。here doc テキスト ブロックを処理せずにそのまま追加するにはどうすればよいですか?
[root@localhost]# cat here_example.sh
#!/bin/sh
cat > todel.txt << heredoc
<?php
$a=b
# this is comment
?>
heredoc
[root@localhost]# cat todel.txt
<?php
=b
# this is comment
?>