3 ms·
>> This will take care of two very common errors: >> Referencing undefined variables (which default to "") >> Ignoring failing commands Better is subjective
by njharman 13y ago
>> This will take care of two very common errors:
>> Referencing undefined variables (which default to "")
>> Ignoring failing commands
Better is subjective... About half my scripts depend on those features. For default arguments, and fail early.
- skywhopper 13y agoHe's advocating fail early with "set -e". And as for the other, you can allow overrides with syntax like: COULD_BE_SET=${COULD_BE_SET:altvalue}