Thread (2 messages) flat view 2 messages, 2 authors, 2016-06-15

Re: calling git rebase with invalid onto-ref exits with wrong error message

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:53:56

Possibly related (same subject, not in this thread)

Erik Faye-Lund [off-list ref] writes:
Indeed. This looks like the result of a bad merge-resolution, but I
could be mistaken.
It looks like 9765b6a (rebase: align variable content, 2011-02-06)
originally botched it, which propagated to 71786f5 (rebase: factor
out reference parsing, 2011-02-06) in the series, and finally merged
at 78c6e0f (Merge branch 'mz/rebase', 2011-04-28).
quoted hunk
This looks like the correct solution to me:
diff --git a/git-rebase.sh b/git-rebase.sh
index 24a2840..3267c92 100755
--- a/git-rebase.sh
+++ b/git-rebase.sh
@@ -423,7 +423,7 @@ case "$onto_name" in
 	;;
 *)
 	onto=$(git rev-parse --verify "${onto_name}^0") ||
-	die "Does not point to a valid commit: $1"
+	die "Does not point to a valid commit: $onto_name"
 	;;
 esac
Yes, it does.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help