Answers for "spawn a shell with python"

4

python spawn shell

python -c 'import pty;pty.spawn("/bin/bash")'
Posted by: Guest on May-11-2020
23

execute command in python script

import os

os.system("ma Commande")

#Exemple:

os.system("cd Documents")
Posted by: Guest on June-10-2020

Python Answers by Framework

Browse Popular Code Answers by Language