I have a script say abc.sh which needs to be executed by another script as
. ../abc.sh
but the control never returns to the calling script. The control does come back if I use
../abc.sh
but then abc.sh is run as child script.
Please tell me how do I bring the control back to the calling script so that the calling script can read the exported variables from the called script.
abc.sh (just for demonstration) is as under:
#/bin/ksh -x
DEFAULT_DB=tektips
export DEFAULT_DB
if [ $DEFAULT_DB = "tektips" ]; then
exit 0
else
exit 1
fi
. ../abc.sh
but the control never returns to the calling script. The control does come back if I use
../abc.sh
but then abc.sh is run as child script.
Please tell me how do I bring the control back to the calling script so that the calling script can read the exported variables from the called script.
abc.sh (just for demonstration) is as under:
#/bin/ksh -x
DEFAULT_DB=tektips
export DEFAULT_DB
if [ $DEFAULT_DB = "tektips" ]; then
exit 0
else
exit 1
fi