{"thread":{"id":"14308","subject":"[PATCH v2] Make rebase save ORIG_HEAD if changing current branch","startedAt":"2008-07-06T08:40:58Z","lastAt":"2008-07-06T16:16:03Z","messageCount":2,"participants":["Brian Gernhardt"],"isPatch":true,"patchVersion":2,"patchTotal":null},"messages":[{"id":"82344","messageId":"1215333658-84938-1-git-send-email-benji@silverinsanity.com","threadId":"14308","inReplyTo":null,"subject":"[PATCH v2] Make rebase save ORIG_HEAD if changing current branch","fromName":"Brian Gernhardt","fromEmail":"benji@silverinsanity.com","sentAt":"2008-07-06T08:40:58Z","receivedAt":"2008-07-06T08:40:58Z","isPatch":true,"sender":{"key":"benji@silverinsanity.com","avatar":"https://gravatar.com/avatar/e06c101dbc25c68114d859b4a9ec7cf8a2c52fd2b0270ef0eac0e2e63ff22311?d=mp&s=160"},"body":"This makes rebase act a little more like merge when working on the\ncurrent branch.  This is particularly useful for `git pull --rebase`\n\nSigned-off-by: Brian Gernhardt <benji@silverinsanity.com>\n---\n\n If I followed the discussion the last time I sent this in correctly,\n the two issues were:\n\n - Ugly \"echo > ORIG_HEAD\" instead of pretty \"git update-ref ORIG_HEAD\"\n - Setting ORIG_HEAD at the wrong place\n\n Let me know if there are any other issues.\n\n git-rebase.sh |    1 +\n 1 files changed, 1 insertions(+), 0 deletions(-)\n\ndiff --git a/git-rebase.sh b/git-rebase.sh\nindex e2d85ee..44db7e6 100755\n--- a/git-rebase.sh\n+++ b/git-rebase.sh\n@@ -434,3 +434,4 @@ do\n done\n \n finish_rb_merge\n+git update-ref ORIG_HEAD $orig_head\n-- \n1.5.6.1.324.gc55f7\n"},{"id":"82375","messageId":"1215360963-85805-1-git-send-email-benji@silverinsanity.com","threadId":"14308","inReplyTo":"1215333658-84938-1-git-send-email-benji@silverinsanity.com","subject":"[PATCH v3] Make rebase save ORIG_HEAD if changing current branch","fromName":"Brian Gernhardt","fromEmail":"benji@silverinsanity.com","sentAt":"2008-07-06T16:16:03Z","receivedAt":"2008-07-06T16:16:03Z","isPatch":true,"sender":{"key":"benji@silverinsanity.com","avatar":"https://gravatar.com/avatar/e06c101dbc25c68114d859b4a9ec7cf8a2c52fd2b0270ef0eac0e2e63ff22311?d=mp&s=160"},"body":"This makes rebase act a little more like merge when working on the\ncurrent branch.  This is particularly useful for `git pull --rebase`\n\nSigned-off-by: Brian Gernhardt <benji@silverinsanity.com>\n---\n\n Okay, I apparently should stop coding after midnight, even if I think I'm\n awake enough.  This version uses the correct variable.  $orig_head looks like\n the right name, but it stores the symbolic ref.  $prev_head stores the actual\n SHA1, which is what I was looking for.\n\n git-rebase.sh |    1 +\n 1 files changed, 1 insertions(+), 0 deletions(-)\n\ndiff --git a/git-rebase.sh b/git-rebase.sh\nindex e2d85ee..44db7e6 100755\n--- a/git-rebase.sh\n+++ b/git-rebase.sh\n@@ -434,3 +434,4 @@ do\n done\n \n finish_rb_merge\n+git update-ref ORIG_HEAD $orig_head\n-- \n1.5.6.2.337.gf6537\n"}]}