Exporting to a super shell
How do I export to a super thread.
If I export say test
export test="Somthing"
that only make $test equal "Something" in sub Shells
How do I ""export"" a variable so that it is available in the shell that called the file. ie
file1:
#! /bin/sh
echo $TEST
./file2
echo $TEST
file2:
#! /bin/sh
Some Command $TEST="SOMETHING"
So that running file1 produces this output
<NOTHING HERE TEST NOT SET YET>
"SOMETHING"
Thanks
|