Help newbie with how to call a source command

Joni Lee webcokies at yahoo.com
Thu Aug 13 19:52:46 CEST 2009


Hi all,
 
I'm landing here because I need some help that I couldn't get through it.
Question 1. 
I want to call a source command from python script. It will source some variables enviroment for further commands. I tried the following which did not work
os.sys('source '+source_text)
call(['source',source_text], shell=True)
commands.getoutput('source '+source_text)
 
Anyone have experiences with this? Because I'm very new to this world so a details reply is really appreciated!!! thank you very much
 
Question 2.
I call a shell command from python, this time it runs a script which runs some ruby scripts. And the error returns: "ruby: command not found"
 
Thank you again


      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20090813/0f37d67f/attachment.html>


More information about the Python-list mailing list