Posts by Pedro Souza • 43 points
2 posts
-
1
votes1
answer174
viewsQ: Python lib subprocess
Does anyone know why he opens the 2 terminals with the same command " ls-la " ? import subprocess cmd = ["xterm"] cmd.extend(['-e','bash','-c', 'ls -la; exec $SHELL']) subprocess.Popen(cmd,…
python-2.7asked Pedro Souza 43 -
3
votes1
answer1222
viewsQ: Calling another terminal with python
I’m doing a project here and I need to open another terminal window, which runs the command ls. I’ve tried with subprocess but it was a mistake: Traceback (most recent call last): File "tests.py",…