bash - pipe here document command to log file -
quite i'll use following construct pipe output log file, keeping output on display
./command 2>&1 | tee output.log
i'm trying similar, using here document:
./command << heredoc params heredoc 2>&1 | tee output.log
this doesn't work - possible achieve this?
sure.
./command <<heredoc 2>&1 | tee output.log params heredoc
the here-document doesn't begin until next line. rest of command parsed normal.
Comments
Post a Comment