I have a script that should be run in background. I must answer a question as soon as I run the bash..How can I do that?
(nohup python script.py lst '<<HERE yes HERE' &)
I have a script that should be run in background. I must answer a question as soon as I run the bash..How can I do that?
(nohup python script.py lst '<<HERE yes HERE' &)
The <<
heredoc is multiline, like
somescript <<EOF &
input
EOF
the heredoc delimiter should be alone on the final line
You can use one line heredoc with <<<
, like:
somescript <<<"this coming from stdin" &