From: Csaba Henk Date: Fri, 27 May 2011 20:13:02 +0000 (-0400) Subject: rebase: create HEAD reflog entry when aborting X-Git-Tag: v1.7.6-rc0~8^2~1 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=ea69619cd1081359e73e597a76fcf6444f222f2d;p=git.git rebase: create HEAD reflog entry when aborting When we abort a rebase, we return to the original value of HEAD. Failing to write a reflog entry means we create a gap in the reflog (which can cause "git show HEAD@{5.minutes.ago}" to issue a warning). Plus having the extra entry makes the reflog easier to follow for a human. Signed-off-by: Jeff King Signed-off-by: Junio C Hamano --- diff --git a/git-rebase.sh b/git-rebase.sh index 7a54bfc61..57cbe49ea 100755 --- a/git-rebase.sh +++ b/git-rebase.sh @@ -332,7 +332,7 @@ abort) read_basic_state case "$head_name" in refs/*) - git symbolic-ref HEAD $head_name || + git symbolic-ref -m "rebase: aborting" HEAD $head_name || die "Could not move back to $head_name" ;; esac