We have two scripts, first.sh and second.sh. We run first.sh from second.sh using the . (source) command.
I am stuck at this script,
first.sh
value="myvalue"
export value
oldvalue="othervalue"
export value
After initializing the value and exporting, we have initialized the oldvalue and again exported value instead of oldvalue , but still the othervalue is available in the script second.sh, even though we didn't export oldvalue in first.sh.