The heredoc program
heredoc runs a command with a certain string fed to a
heredoc [ -d ] fd string prog...
- heredoc execs into prog... with
string available on the fd file
- string must not contain a null character.
- -d : run the process feeding string to fd
as a grandchild of heredoc. This is meant to prevent a zombie
from hanging around if prog... has read string and fails
to wait for its children.
- heredoc is meant to be used in place of the shell
<< construct, which includes here-documents