From 397dfe67c71fdd673bb108b9c6103e4a5e750edb Mon Sep 17 00:00:00 2001
From: Bob Proulx <bob@proulx.com>
Date: Thu, 11 Jan 2007 23:45:38 -0700
Subject: [PATCH] git-revert: Fix die before git-sh-setup defines it.

The code previously checked it's own name and called 'die' upon
an error.  However 'die' was not yet defined because git-sh-setup
had not been sourced yet.  Instead simply write the error message
to stderr and exit with an error as was originally desired.

Signed-off-by: Bob Proulx <bob@proulx.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
---
 git-revert.sh | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/git-revert.sh b/git-revert.sh
index f9843c7c8ec..fcca3ebb90e 100755
--- a/git-revert.sh
+++ b/git-revert.sh
@@ -16,7 +16,8 @@ case "$0" in
 	me=cherry-pick
 	USAGE='[--edit] [-n] [-r] [-x] <commit-ish>'  ;;
 * )
-	die "What are you talking about?" ;;
+	echo >&2 "What are you talking about?"
+	exit 1 ;;
 esac
 . git-sh-setup
 require_work_tree