For instance, if I want to run from a shell script something in python I would do:
echo 'print("hello world")' | python2
Now imagine I want to run something interactive, i.e., it needs my input, for instance
name = raw_input("Enter your name:")
By doing:
echo 'name = raw_input("Enter your name:")' | python2
I get an error. So how is the correct way to run something from bash but that I can interact with?
PS - this is simply an example. I need to run a set of scripts in a different external program (not python), and some of these scripts need some input from the user. Everything runs smoothly until the point when there is the need for input, where the current script crashes and passes to the next.
Thanks :)