{"thread":{"id":"11904","subject":"[BUG] Rebase, squash, and conflicts","startedAt":"2008-02-05T21:27:56Z","lastAt":"2008-02-05T21:27:56Z","messageCount":1,"participants":["Daniel Barkalow"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"67559","messageId":"alpine.LNX.1.00.0802051618190.13593@iabervon.org","threadId":"11904","inReplyTo":null,"subject":"[BUG] Rebase, squash, and conflicts","fromName":"Daniel Barkalow","fromEmail":"barkalow@iabervon.org","sentAt":"2008-02-05T21:27:56Z","receivedAt":"2008-02-05T21:27:56Z","isPatch":false,"sender":{"key":"barkalow@iabervon.org","avatar":"https://avatars.githubusercontent.com/u/55364219?v=4"},"body":"I think there's a bug in the squash behavior for git rebase -i. Say you've \ngot the following history:\n\naaaaa introduce an API\nbbbbb use the API in new code\nccccc some unrelated review\nddddd fix the API due to review\n\nAnd you do the following rebase:\n\npick aaaaa introduce an API\nsquash ddddd fix the API due to review\npick bbbbb use the API in new code\npick ccccc some unrelated review\npick ddddd fix the API due to review\n\n(the last line being because some of the changes don't apply between a and \nb, so we want to duplicate the commit later, and probably squash it into \nb, but that's not part of this bug report)\n\nYou get a conflict on the second item, which you expected. But when you \nresolve it, it squashes 3/5 into 2/5, not 2/5 into 1/5. I think this is \nbecause rebase --continue isn't noticing that it's a squash that needed \nhelp. It seems to work fine to do this in two steps (pick instead of \nsquash, followed by another rebase that does the squash when it's \nunconflicted), as a workaround.\n\n\t-Daniel\n*This .sig left intentionally blank*\n"}]}