mirror of
https://github.com/git/git
synced 2024-08-27 19:49:21 +00:00
[PATCH] Make git-checkout failure message more friendly.
... or less so, perhaps ;-). Suggested by Jeff Garzik. Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
parent
0e60471c2a
commit
6b82d16bfc
|
@ -22,7 +22,8 @@ while [ "$#" != "0" ]; do
|
|||
force=1
|
||||
;;
|
||||
*)
|
||||
rev=$(git-rev-parse --verify "$arg^0") || exit
|
||||
rev=$(git-rev-parse --verify "$arg^0" 2>/dev/null) ||
|
||||
die "hey dummy, branch '$arg' doesn't exist."
|
||||
if [ -z "$rev" ]; then
|
||||
echo "unknown flag $arg"
|
||||
exit 1
|
||||
|
|
Loading…
Reference in a new issue