Call 'script' command and exit it from within a bash script
- by William Jamieson
I'm using the linux 'script' command http://www.linuxcommand.org/man_pages/script1.html to log all input and output in an interactive bash script.
At the moment I have to call the script command, then run my bash script, then exit.
I want to run the script and exit commands from within the actual bash script itself. How can I do this?
I've tried script -a but that doesn't work for interactive scripts.
Any assistance would be greatly appreciated.