On 09Jul2014 11:42, Steven D'Aprano <[email protected]> wrote:
On Tue, Jul 08, 2014 at 03:45:42PM -0500, Jim Byrnes wrote:
I would like to automate running virtualenv with a python script by:
opening gnome-terminal
cd to proper directory
run source /bin/activate
Why not just run /bin/activate directly from Python?
os.chdir("the/proper/directory")
os.system("/bin/activate")
Because "activate" needs to be sourced by the shell. It hacks the environment.
Cheers,
Cameron Simpson <[email protected]>
If at first you don't succeed, your sky-diving days are over.
- Paul Blumstein, [email protected], DoD #36
_______________________________________________
Tutor maillist - [email protected]
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor