commit: zshrc: using FOO=${FOO:-default} instead of (( ${+FOO} )) || FOO=default
Frank Terbeck
ft at repos.grml.org
Sat Feb 2 10:41:33 CET 2008
Changeset available online at:
http://hg.grml.org/grml-etc-core/rev/e77701968070dc524be94a6d006ab24f3b7dce63
changeset: 380:e77701968070dc524be94a6d006ab24f3b7dce63
tag: tip
user: Frank Terbeck <ft at grml.org>
date: Sat Feb 02 10:41:09 2008 +0100
files: etc/zsh/zshrc
description:
zshrc: using FOO=${FOO:-default} instead of (( ${+FOO} )) || FOO=default
This is more correct, IMHO.
The old way only sets the default if $FOO is unset; whereas the new way
sets the default if $FOO is unset *or* empty (which is certainly desirable,
if you think of variables like $PAGER).
More information about the Git-commits
mailing list