Basics
Variables¶
You must omit the $ when assigning a variable, but must use include it when referencing.
So this example:
isLive=${1:-false};
dbName="localDbName";
if [[ isLive == true ]]
then
dbName="liveDbName"
fi
isLive="${1:-false}";
dbName="localDbName";
if [[ "$isLive" == "true" ]]
then
dbName="liveDbName"
fi