of python script
beginning of shell script
#!/bin/sh
num=2
text=`python numtotext.py $num`
echo $num as text is $text
end of shell script
bye
N
devi thapa wrote:
Hi,
I am executing a python script in a shell script. The python script
actually returns a value.
So, can I get the return value
devi thapa wrote:
I am executing a python script in a shell script. The python script
actually returns a value.
So, can I get the return value in a shell script? If yes, then help me
out.
Yes. The variable $? should be bound to the return value of the last
foreground program to exit
Look at os._exit()
On Wed, Nov 12, 2008 at 6:36 PM, devi thapa [EMAIL PROTECTED] wrote:
Hi,
I am executing a python script in a shell script. The python script
actually returns a value.
So, can I get the return value in a shell script? If yes, then help me out.
Regards,
Devi
--
http
On Nov 12, 8:19 am, D'Arcy J.M. Cain [EMAIL PROTECTED] wrote:
On Wed, 12 Nov 2008 13:09:21 +
Tom Wright [EMAIL PROTECTED] wrote:
devi thapa wrote:
I am executing a python script in a shell script. The python script
actually returns a value.
So, can I get the return value
On 2008-11-12, devi thapa [EMAIL PROTECTED] wrote:
I am executing a python script in a shell script. The python
script actually returns a value. So, can I get the return
value in a shell script? If yes, then help me out.
There are two ways to return something to a shell script.
1
On Wed, 12 Nov 2008 13:09:21 +
Tom Wright [EMAIL PROTECTED] wrote:
devi thapa wrote:
I am executing a python script in a shell script. The python script
actually returns a value.
So, can I get the return value in a shell script? If yes, then help me
out.
Yes. The variable
On Wed, Nov 12, 2008 at 2:06 PM, devi thapa [EMAIL PROTECTED] wrote:
Hi,
I am executing a python script in a shell script. The python script
actually returns a value.
So, can I get the return value in a shell script? If yes, then help me out.
Regards,
Devi
--
http://mail.python.org
Hi,
I am executing a python script in a shell script. The python script
actually returns a value.
So, can I get the return value in a shell script? If yes, then help me out.
Regards,
Devi
--
http://mail.python.org/mailman/listinfo/python-list