Re: How to pass shell variable to shell script from python
Rockins Chen wrote:
> Hi all,
> I encountered a problem: I have a python script, let's just name it
> caller.py, It calls a shell script, which is named callee.sh. In callee.sh,
> it need a shell variable $target, which should be supplied by caller.py(cannot
> pass by argument). I try to use os.environ to do this, as follows:
Don't use os.system or the popen functions. They have been substituted
with the subprocess module. It has a way to pass a new environment to a
|All times are GMT. The time now is 05:06 AM.|
Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.