vendredi 11 septembre 2015

Equivalent to parameter expansion in shell script

I understood parameter expansion

a = ${b:-c}

which will assign content of 'b' to a if 'b' is set and else content of 'c'

Is there anyway I can directly do a="123":-"456" rather than storing '123' to variable and '456' to another variable.



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire