{"thread":{"id":"10286","subject":"[PATCH] git-rebase: document suppression of duplicate commits","startedAt":"2007-10-15T04:47:30Z","lastAt":"2007-10-15T09:47:51Z","messageCount":2,"participants":["Jeff King","Michael Witten"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"55812","messageId":"20071015044730.GA12118@coredump.intra.peff.net","threadId":"10286","inReplyTo":null,"subject":"[PATCH] git-rebase: document suppression of duplicate commits","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2007-10-15T04:47:30Z","receivedAt":"2007-10-15T04:47:30Z","isPatch":true,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"git-rebase uses format-patch's --ignore-if-in-upstream\noption, but we never document the user-visible behavior. The\nexample is placed near the top of the example list rather\nthan at the bottom because it is:\n  a. a simple example\n  b. a reasonably common scenario for many projects (mail\n     some patches which get accepted upstream, then rebase)\n\nSigned-off-by: Jeff King <peff@peff.net>\n---\nOn Sat, Oct 13, 2007 at 07:04:52PM -0400, Michael Witten wrote:\n> I can make a patch, but at the moment I'm swamped and I don't want to\n> think about doing that.\n\nAnd whoever said procrastination didn't get things done?\n\n Documentation/git-rebase.txt |   25 ++++++++++++++++++++++++-\n 1 files changed, 24 insertions(+), 1 deletions(-)\n\ndiff --git a/Documentation/git-rebase.txt b/Documentation/git-rebase.txt\nindex e8e7579..b6efb48 100644\n--- a/Documentation/git-rebase.txt\n+++ b/Documentation/git-rebase.txt\n@@ -28,7 +28,10 @@ The current branch is reset to <upstream>, or <newbase> if the\n `git reset --hard <upstream>` (or <newbase>).\n \n The commits that were previously saved into the temporary area are\n-then reapplied to the current branch, one by one, in order.\n+then reapplied to the current branch, one by one, in order. Note that\n+any commits in HEAD which introduce the same textual changes as a commit\n+in <upstream>..HEAD are omitted (i.e., a patch already accepted upstream\n+with a different commit message or timestamp will be skipped).\n \n It is possible that a merge failure will prevent this process from being\n completely automatic.  You will have to resolve any such merge failure\n@@ -62,6 +65,26 @@ would be:\n The latter form is just a short-hand of `git checkout topic`\n followed by `git rebase master`.\n \n+If the upstream branch already contains a change you have made (e.g.,\n+because you mailed a patch which was applied upstream), then that commit\n+will be skipped. For example, running `git-rebase master` on the\n+following history (in which A' and A introduce the same set of changes,\n+but have different committer information):\n+\n+------------\n+          A---B---C topic\n+         /\n+    D---E---A'---F master\n+------------\n+\n+will result in:\n+\n+------------\n+                   B'---C' topic\n+                  /\n+    D---E---A'---F master\n+------------\n+\n Here is how you would transplant a topic branch based on one\n branch to another, to pretend that you forked the topic branch\n from the latter branch, using `rebase --onto`.\n-- \n1.5.3.4.1155.gfe96ee-dirty\n"},{"id":"55842","messageId":"4C8A9577-F2DD-4C5E-98FD-37D27E90E897@MIT.EDU","threadId":"10286","inReplyTo":"20071015044730.GA12118@coredump.intra.peff.net","subject":"Re: [PATCH] git-rebase: document suppression of duplicate commits","fromName":"Michael Witten","fromEmail":"mfwitten@mit.edu","sentAt":"2007-10-15T09:47:51Z","receivedAt":"2007-10-15T09:47:51Z","isPatch":true,"sender":{"key":"mfwitten@gmail.com","avatar":"https://avatars.githubusercontent.com/u/597101?v=4"},"body":"\nOn 15 Oct 2007, at 12:47:30 AM, Jeff King wrote:\n\n> On Sat, Oct 13, 2007 at 07:04:52PM -0400, Michael Witten wrote:\n>> I can make a patch, but at the moment I'm swamped and I don't want to\n>> think about doing that.\n>\n> And whoever said procrastination didn't get things done?\n\n:-)\n\nThanks.\n\nI'm pretty bad at setting priories, so I apologize for\nsaying I'm swamped and then turning around to submit\nother patches.\n\nSincerely,\nMichael Witten\n"}]}