2 ms·
set -u Another great thing I could have read in the effin manual. He could have added a little reminder about the ${VAR:-default} syntax. [[ http://www.ooblic
by agumonkey 15y ago
set -u
Another great thing I could have read in the effin manual.
He could have added a little reminder about the ${VAR:-default} syntax. [[ http://www.ooblick.com/text/sh/ http://www.ooblick.com/text/sh/ search for Quasi-variable constructs ]]
Great read, thanks.
- veyron 15y agoOr look at the manpage ${parameter:-word} Use Default Values. If parameter is unset or null, the expan- sion of word is substituted. Otherwise, the value of parameter is substituted.
- agumonkey 15y agoAgreed, I was just sayin for the sake of the article, he brings up the subject of unitialized variables, without mentioning this other way.