From bc6188375e6ed28311fed0b30b7048c1b88f70d8 Mon Sep 17 00:00:00 2001 From: Colin Patrick Mccabe Date: Tue, 14 Feb 2012 08:12:14 -0800 Subject: [PATCH] git-identity.sh: improve usage Signed-off-by: Colin McCabe --- git-identity.sh | 6 ++++-- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/git-identity.sh b/git-identity.sh index 5c4c0f1..07cf63d 100755 --- a/git-identity.sh +++ b/git-identity.sh @@ -11,7 +11,9 @@ die() { exit 1 } -[ $# -eq 1 ] || die "You must supply one argument: work or priv" +USAGE="You must supply one argument: work or priv" + +[ $# -eq 1 ] || die "${USAGE}" case $1 in work) git config user.email cmccabe@cloudera.com --file || die "${LINENO}" @@ -22,7 +24,7 @@ case $1 in git config user.name "Colin Patrick Mccabe" --file || die "${LINENO}" ;; *) - die "logic error" + die "${USAGE}" ;; esac -- 1.6.6.rc1.39.g9a42