summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 2c162b5)
raw | patch | inline | side by side (parent: 2c162b5)
author | Fredrik Gustafsson <iveqy@iveqy.com> | |
Thu, 9 Jun 2011 07:47:02 +0000 (09:47 +0200) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Mon, 13 Jun 2011 18:23:28 +0000 (11:23 -0700) |
This behaves similar to "die" but can exit with status different from the
usual 1.
Signed-off-by: Fredrik Gustafsson <iveqy@iveqy.com>
Mentored-by: Jens Lehmann <Jens.Lehmann@web.de>
Mentored-by: Heiko Voigt <hvoigt@hvoigt.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
usual 1.
Signed-off-by: Fredrik Gustafsson <iveqy@iveqy.com>
Mentored-by: Jens Lehmann <Jens.Lehmann@web.de>
Mentored-by: Heiko Voigt <hvoigt@hvoigt.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-sh-setup.sh | patch | blob | history |
diff --git a/git-sh-setup.sh b/git-sh-setup.sh
index 94e26ed5e8dcf84c4f238c76b6c508dc84d0b7ea..8e427dab31c27bd78d9eac1ad15bc1f5dcc044c4 100644 (file)
--- a/git-sh-setup.sh
+++ b/git-sh-setup.sh
# @@BROKEN_PATH_FIX@@
-die() {
- echo >&2 "$@"
- exit 1
+die () {
+ die_with_status 1 "$@"
+}
+
+die_with_status () {
+ status=$1
+ shift
+ echo >&2 "$*"
+ exit "$status"
}
GIT_QUIET=