Message249425
erykson's example works perfectly.
I have a script as follows
#!/bin/python
#
import os
cmd = os.environ.get('XRIT_DECOMPRESS_PATH')
print cmd
resulting in 'None'
and if I substitute this line
cmd = os.environ.get('PATH')
resulting in '/usr/local/bin:/usr/bin:/bin:/opt/bin:/usr/x86_64-pc-linux-gnu/gcc-bin/4.8.4:/usr/include/KDE'
however from the bash prompt
$ echo $XRIT_DECOMPRESS_PATH
results in '/usr/local/bin/xRITDecompress' so the environment variable is there and available in bash, but not in Python.
I find this very strange |
|
Date |
User |
Action |
Args |
2015-08-31 20:18:36 | themetman | set | recipients:
+ themetman, r.david.murray, eryksun |
2015-08-31 20:18:36 | themetman | set | messageid: <1441052316.09.0.519697318281.issue24971@psf.upfronthosting.co.za> |
2015-08-31 20:18:36 | themetman | link | issue24971 messages |
2015-08-31 20:18:35 | themetman | create | |
|