{"thread":{"id":"1281","subject":"Should cg-mkpatch output be usable with cg-patch?","startedAt":"2005-07-20T23:49:04Z","lastAt":"2005-07-24T22:48:30Z","messageCount":6,"participants":["Wolfgang Denk","Junio C Hamano","Petr Baudis"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"6285","messageId":"20050720234904.B3ED735267C@atlas.denx.de","threadId":"1281","inReplyTo":null,"subject":"Should cg-mkpatch output be usable with cg-patch?","fromName":"Wolfgang Denk","fromEmail":"wd@denx.de","sentAt":"2005-07-20T23:49:04Z","receivedAt":"2005-07-20T23:49:04Z","isPatch":false,"sender":{"key":"wd@denx.de","avatar":null},"body":"I wander what I should do with \"cg-mkpatch\" generated output;  I  had\nthe  impression that this should be usable with \"cg-patch\", but these\nare incompatible with each other. Forexample. if  a  commit  contains\npermission changes, my generated patch may look like this:\n\n\t...\n\tdiff --git a/MAKEALL b/MAKEALL\n\told mode 100644\n\tnew mode 100755\n\tdiff --git a/mkconfig b/mkconfig\n\told mode 100644\n\tnew mode 100755\n\tdiff --git a/tools/img2brec.sh b/tools/img2brec.sh\n\told mode 100644\n\tnew mode 100755\n\t...\n\nIf I feed this into \"cg-patch\", I get:\n\n\tpatch: **** Only garbage was found in the patch input.\n\n-> rpm -q cogito\ncogito-0.12.1-1\n\n\nBest regards,\n\nWolfgang Denk\n\n-- \nSoftware Engineering:  Embedded and Realtime Systems,  Embedded Linux\nPhone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de\nI really hate this damned machine     It never does quite what I want\nI wish that they would sell it.              But only what I tell it.\n"},{"id":"6286","messageId":"7vackgerpe.fsf@assigned-by-dhcp.cox.net","threadId":"1281","inReplyTo":"20050720234904.B3ED735267C@atlas.denx.de","subject":"Re: Should cg-mkpatch output be usable with cg-patch?","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2005-07-21T03:57:49Z","receivedAt":"2005-07-21T03:57:49Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Wolfgang Denk <wd@denx.de> writes:\n\n> I wander what I should do with \"cg-mkpatch\" generated output;  I  had\n> the  impression that this should be usable with \"cg-patch\", but these\n> are incompatible with each other. Forexample. if  a  commit  contains\n> permission changes, my generated patch may look like this:\n\nYes, cg-patch does grok git extended diff headers, but does it\nby hand and missing corner cases like this is understandable.\n\nI only briefly looked at cg-patch, but I suspect that it can\nlose 90% lines of its code by just using \"git-apply --index\".\n\nI see cg-patch wants to be able to do reverse patch, which is\nnot supported by git-apply currently.\n\nDo people find \"cg-patch -R\" useful?\n"},{"id":"6320","messageId":"20050722210225.GF11916@pasky.ji.cz","threadId":"1281","inReplyTo":"7vackgerpe.fsf@assigned-by-dhcp.cox.net","subject":"Re: Should cg-mkpatch output be usable with cg-patch?","fromName":"Petr Baudis","fromEmail":"pasky@suse.cz","sentAt":"2005-07-22T21:02:25Z","receivedAt":"2005-07-22T21:02:25Z","isPatch":false,"sender":{"key":"pasky@ucw.cz","avatar":"https://avatars.githubusercontent.com/u/18439?v=4"},"body":"Dear diary, on Thu, Jul 21, 2005 at 05:57:49AM CEST, I got a letter\nwhere Junio C Hamano <junkio@cox.net> told me that...\n> I only briefly looked at cg-patch, but I suspect that it can\n> lose 90% lines of its code by just using \"git-apply --index\".\n\nCan git-apply already deal with fuzzy patches?\n\n-- \n\t\t\t\tPetr \"Pasky\" Baudis\nStuff: http://pasky.or.cz/\nIf you want the holes in your knowledge showing up try teaching\nsomeone.  -- Alan Cox\n"},{"id":"6319","messageId":"20050722210352.GG11916@pasky.ji.cz","threadId":"1281","inReplyTo":"20050720234904.B3ED735267C@atlas.denx.de","subject":"Re: Should cg-mkpatch output be usable with cg-patch?","fromName":"Petr Baudis","fromEmail":"pasky@suse.cz","sentAt":"2005-07-22T21:03:52Z","receivedAt":"2005-07-22T21:03:52Z","isPatch":false,"sender":{"key":"pasky@ucw.cz","avatar":"https://avatars.githubusercontent.com/u/18439?v=4"},"body":"Dear diary, on Thu, Jul 21, 2005 at 01:49:04AM CEST, I got a letter\nwhere Wolfgang Denk <wd@denx.de> told me that...\n> I wander what I should do with \"cg-mkpatch\" generated output;  I  had\n> the  impression that this should be usable with \"cg-patch\", but these\n> are incompatible with each other.\n\nThey certainly aren't.\n\n> Forexample. if  a  commit  contains permission changes, my generated\n> patch may look like this:\n> \n> \t...\n> \tdiff --git a/MAKEALL b/MAKEALL\n> \told mode 100644\n> \tnew mode 100755\n> \tdiff --git a/mkconfig b/mkconfig\n> \told mode 100644\n> \tnew mode 100755\n> \tdiff --git a/tools/img2brec.sh b/tools/img2brec.sh\n> \told mode 100644\n> \tnew mode 100755\n> \t...\n> \n> If I feed this into \"cg-patch\", I get:\n> \n> \tpatch: **** Only garbage was found in the patch input.\n\nAnd did the changes apply? :-)\n\nThe message is surely confusing, but appeared to be rather corner-casy\nand after I imagined the required complexity of filtering this, I\ndecided to spend my time on something more useful for the time being. :)\n\n-- \n\t\t\t\tPetr \"Pasky\" Baudis\nStuff: http://pasky.or.cz/\nIf you want the holes in your knowledge showing up try teaching\nsomeone.  -- Alan Cox\n"},{"id":"6412","messageId":"20050724175018.3D721352B73@atlas.denx.de","threadId":"1281","inReplyTo":"20050722210352.GG11916@pasky.ji.cz","subject":"Re: Should cg-mkpatch output be usable with cg-patch?","fromName":"Wolfgang Denk","fromEmail":"wd@denx.de","sentAt":"2005-07-24T17:50:18Z","receivedAt":"2005-07-24T17:50:18Z","isPatch":false,"sender":{"key":"wd@denx.de","avatar":null},"body":"In message <20050722210352.GG11916@pasky.ji.cz> you wrote:\n>\n> > I wander what I should do with \"cg-mkpatch\" generated output;  I  had\n> > the  impression that this should be usable with \"cg-patch\", but these\n> > are incompatible with each other.\n> \n> They certainly aren't.\n\nIs this a problem with the current implementation, or intentional?\n\n> > \tdiff --git a/tools/img2brec.sh b/tools/img2brec.sh\n> > \told mode 100644\n> > \tnew mode 100755\n> > \t...\n> > If I feed this into \"cg-patch\", I get:\n> > \tpatch: **** Only garbage was found in the patch input.\n> \n> And did the changes apply? :-)\n\nNo, they did not. No file modes were changed.\n\n> The message is surely confusing, but appeared to be rather corner-casy\n> and after I imagined the required complexity of filtering this, I\n> decided to spend my time on something more useful for the time being. :)\n\nI don't think this is a corner case. I think it is  pretty  important\nto be able to promote permissiong changes.\n\n\nBest regards,\n\nWolfgang Denk\n\n-- \nSoftware Engineering:  Embedded and Realtime Systems,  Embedded Linux\nPhone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de\nToo many people are ready to carry the stool when the piano needs  to\nbe moved.\n"},{"id":"6414","messageId":"20050724224830.GG7601@pasky.ji.cz","threadId":"1281","inReplyTo":"20050724175018.3D721352B73@atlas.denx.de","subject":"Re: Should cg-mkpatch output be usable with cg-patch?","fromName":"Petr Baudis","fromEmail":"pasky@suse.cz","sentAt":"2005-07-24T22:48:30Z","receivedAt":"2005-07-24T22:48:30Z","isPatch":false,"sender":{"key":"pasky@ucw.cz","avatar":"https://avatars.githubusercontent.com/u/18439?v=4"},"body":"Dear diary, on Sun, Jul 24, 2005 at 07:50:18PM CEST, I got a letter\nwhere Wolfgang Denk <wd@denx.de> told me that...\n> In message <20050722210352.GG11916@pasky.ji.cz> you wrote:\n> >\n> > > I wander what I should do with \"cg-mkpatch\" generated output;  I  had\n> > > the  impression that this should be usable with \"cg-patch\", but these\n> > > are incompatible with each other.\n> > \n> > They certainly aren't.\n> \n> Is this a problem with the current implementation, or intentional?\n\nImplementation. Should be fixed now, after rewriting part of it. ;-)\n\n> > The message is surely confusing, but appeared to be rather corner-casy\n> > and after I imagined the required complexity of filtering this, I\n> > decided to spend my time on something more useful for the time being. :)\n> \n> I don't think this is a corner case. I think it is  pretty  important\n> to be able to promote permissiong changes.\n\nOf course. By the corner case I meant \"the external patch tool invoked\nby cg-patch emits bogus error in case of patch containing only mode\nchanges and nothing else\". I wasn't aware that the changes wouldn't\napply at all - actually, I was when I was writing the code, but\ncompletely forgot about it later.\n\nThanks,\n\n-- \n\t\t\t\tPetr \"Pasky\" Baudis\nStuff: http://pasky.or.cz/\nIf you want the holes in your knowledge showing up try teaching\nsomeone.  -- Alan Cox\n"}]}