I am trying to write a helper script to shorten some of my project commands.
The script looks like this:
import subprocess
def up():
subprocess.call(['docker-compose', 'up'])
if __name__ == '__main__':
up()
This works, however if I run ctrl + c
, it will kill the script and not the subprocess.
Is there a way I can make the subprocess
the priority for all terminal input until it exits?