{"thread":{"id":"41869","subject":"[BUG?] retrying with \"am -3\" doesn't work anymore","startedAt":"2016-03-30T02:15:02Z","lastAt":"2016-03-30T05:06:42Z","messageCount":3,"participants":["Jeff King","Paul Tan"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"282185","messageId":"20160330021502.GA16077@sigill.intra.peff.net","threadId":"41869","inReplyTo":null,"subject":"[BUG?] retrying with \"am -3\" doesn't work anymore","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2016-03-30T02:15:02Z","receivedAt":"2016-03-30T02:15:02Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"I noticed that I could not get a patch from Junio to apply earlier\ntoday, and I think it is a regression in the builtin git-am\nimplementation.  I had trouble reproducing with a basic test case,\nthough.\n\nBasically, I picked up the three patches from this sub-thread:\n\n  http://thread.gmane.org/gmane.comp.version-control.git/288987/focus=290222\n\nand tried to apply them on top of v2.8.0.\n\nDoing it with \"git am -3 patches\" works. But doing it with:\n\n  git am patches\n  git am -3\n\ndoesn't. Bisecting shows that it did work before 783d7e8 (builtin-am:\nremove redirection to git-am.sh, 2015-08-04).\n\nI tried to tweak t4150 to show this by replacing a \"git am -3 foo\" with\n\"test_must_fail git am foo && git am -3\", but it failed even on older\ngit, which made me think I fumbled the test somehow.\n\n-Peff\n"},{"id":"282190","messageId":"CACRoPnSrKyNS8EdFM119TT9qoUTdNy_+P5q-7rWMahpDzzGAKw@mail.gmail.com","threadId":"41869","inReplyTo":"20160330021502.GA16077@sigill.intra.peff.net","subject":"Re: [BUG?] retrying with \"am -3\" doesn't work anymore","fromName":"Paul Tan","fromEmail":"pyokagan@gmail.com","sentAt":"2016-03-30T04:18:30Z","receivedAt":"2016-03-30T04:18:30Z","isPatch":false,"sender":{"key":"pyokagan@gmail.com","avatar":"https://avatars.githubusercontent.com/u/109479?v=4"},"body":"Hi Jeff,\n\nOn Wed, Mar 30, 2016 at 10:15 AM, Jeff King <peff@peff.net> wrote:\n> I noticed that I could not get a patch from Junio to apply earlier\n> today, and I think it is a regression in the builtin git-am\n> implementation.  I had trouble reproducing with a basic test case,\n> though.\n>\n> Basically, I picked up the three patches from this sub-thread:\n>\n>   http://thread.gmane.org/gmane.comp.version-control.git/288987/focus=290222\n>\n> and tried to apply them on top of v2.8.0.\n>\n> Doing it with \"git am -3 patches\" works. But doing it with:\n>\n>   git am patches\n>   git am -3\n>\n> doesn't. Bisecting shows that it did work before 783d7e8 (builtin-am:\n> remove redirection to git-am.sh, 2015-08-04).\n\nYeah, with \"git am -3\" when resuming, the -3 will only affect the\ncurrent conflicting patch since 852a171 (am: let command-line options\noverride saved options, 2015-08-04).\n\nRegards,\nPaul\n"},{"id":"282193","messageId":"20160330050642.GB11007@sigill.intra.peff.net","threadId":"41869","inReplyTo":"CACRoPnSrKyNS8EdFM119TT9qoUTdNy_+P5q-7rWMahpDzzGAKw@mail.gmail.com","subject":"Re: [BUG?] retrying with \"am -3\" doesn't work anymore","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2016-03-30T05:06:42Z","receivedAt":"2016-03-30T05:06:42Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Wed, Mar 30, 2016 at 12:18:30PM +0800, Paul Tan wrote:\n\n> On Wed, Mar 30, 2016 at 10:15 AM, Jeff King <peff@peff.net> wrote:\n> > I noticed that I could not get a patch from Junio to apply earlier\n> > today, and I think it is a regression in the builtin git-am\n> > implementation.  I had trouble reproducing with a basic test case,\n> > though.\n> >\n> > Basically, I picked up the three patches from this sub-thread:\n> >\n> >   http://thread.gmane.org/gmane.comp.version-control.git/288987/focus=290222\n> >\n> > and tried to apply them on top of v2.8.0.\n> >\n> > Doing it with \"git am -3 patches\" works. But doing it with:\n> >\n> >   git am patches\n> >   git am -3\n> >\n> > doesn't. Bisecting shows that it did work before 783d7e8 (builtin-am:\n> > remove redirection to git-am.sh, 2015-08-04).\n> \n> Yeah, with \"git am -3\" when resuming, the -3 will only affect the\n> current conflicting patch since 852a171 (am: let command-line options\n> override saved options, 2015-08-04).\n\nAh, right. I had a nagging feeling that we had discussed this, and\nindeed, I already participated in the discussion last July[1]. I even\napparently argued in favor of the new behavior[2]. Yikes. There goes my\nmind.\n\nRunning \"git am -3\" for each patch which needs it does indeed\nsuccessfully apply the series.\n\nThanks for a quick response, and sorry for the noise.\n\n-Peff\n\n[1] http://thread.gmane.org/gmane.comp.version-control.git/274574\n\n[2] In http://thread.gmane.org/gmane.comp.version-control.git/274574/focus=274635,\n    though I think there I more meant that in:\n\n       git am\n       git am -3\n       git am\n\n    the third one would not use \"-3\" again. So I was mostly confused\n    that in:\n\n       git am\n       git am -3\n\n    we would not use \"-3\" for the subsequent patches applied by that\n    second invocation. So maybe that is a bug. I dunno. I could see\n    arguments either way.\n"}]}