1 |
Hi all, |
2 |
|
3 |
I'm having difficulties exporting environment variables from within |
4 |
scripts. The problem doesn't seem to occur when exporting variables |
5 |
from the command line. |
6 |
|
7 |
To reiterate with an example, |
8 |
|
9 |
# export VARIABLE='test' |
10 |
# echo $VARIABLE |
11 |
|
12 |
works. However, |
13 |
|
14 |
# echo "export VARIABLE='test'" >> test_script |
15 |
# chmod 754 test_script |
16 |
# ./test_script |
17 |
# echo $VARIABLE |
18 |
|
19 |
does not work. I've also tried the above while omitting the 'export' |
20 |
command, to the same effect. I'm using bash as my shell. I figured |
21 |
that I would try the same with sh instead, but still nothing. |
22 |
|
23 |
I'm using: |
24 |
|
25 |
bash-3.0-r12 |
26 |
|
27 |
Is this a bug, or something that I'm doing wrong? Thanks in advance |
28 |
for your help. |
29 |
|
30 |
Kris Kerwin |