From: Jeff King Date: Fri, 27 May 2011 20:13:02 GMT Subject: [PATCH 1/2] rebase: create HEAD reflog entry when aborting Message-ID: <20110527201302.GA29836@sigill.intra.peff.net> In-Reply-To: From: Csaba Henk 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 --- This is the one that actually gave you trouble. It's different than other cases (dealt with in 2/2) in that it actually creates a gap in the reflog. So I think fixing it is the right thing to do, and your original patch is fine. git-rebase.sh | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/git-rebase.sh b/git-rebase.sh index 7a54bfc..57cbe49 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 -- 1.7.5.3.12.g99e25