{"thread":{"id":"16838","subject":"'Theirs' merge between branches on a binary file.","startedAt":"2008-12-22T20:56:31Z","lastAt":"2008-12-28T17:14:54Z","messageCount":9,"participants":["Tim Visher","Junio C Hamano","René Scharfe"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"98557","messageId":"c115fd3c0812221256l494bb824ga8e1640efb07b20c@mail.gmail.com","threadId":"16838","inReplyTo":null,"subject":"'Theirs' merge between branches on a binary file.","fromName":"Tim Visher","fromEmail":"tim.visher@gmail.com","sentAt":"2008-12-22T20:56:31Z","receivedAt":"2008-12-22T20:56:31Z","isPatch":false,"sender":{"key":"tim.visher@gmail.com","avatar":"https://gravatar.com/avatar/98307ce54bcac1a46b5d845827d5386e2a27895ff08790cdd3877ad527760575?d=mp&s=160"},"body":"Hello Everyone,\n\nI have a binary file that is coming up with a merge conflict\n(obviously) between two branches and I want to simply say, 'take their\nversion of the file'.  Is this possible?  In subversion it's a pretty\ntrivial merge operation, so I assume there's something similar in git.\n\nThanks in advance!\n\n-- \n\nIn Christ,\n\nTimmy V.\n\nhttp://burningones.com/\nhttp://five.sentenc.es/ - Spend less time on e-mail\n"},{"id":"98561","messageId":"7vr63zhq4k.fsf@gitster.siamese.dyndns.org","threadId":"16838","inReplyTo":"c115fd3c0812221256l494bb824ga8e1640efb07b20c@mail.gmail.com","subject":"Re: 'Theirs' merge between branches on a binary file.","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2008-12-22T21:11:23Z","receivedAt":"2008-12-22T21:11:23Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Tim Visher\" <tim.visher@gmail.com> writes:\n\n> I have a binary file that is coming up with a merge conflict\n> (obviously) between two branches and I want to simply say, 'take their\n> version of the file'.\n\nDo you mean during a conflicted merge resolution you would want to check\ntheir version out of the index and declare that it is the merge result?\n"},{"id":"98562","messageId":"c115fd3c0812221316y24ce0c7q29807cd349a99e83@mail.gmail.com","threadId":"16838","inReplyTo":"7vr63zhq4k.fsf@gitster.siamese.dyndns.org","subject":"Re: 'Theirs' merge between branches on a binary file.","fromName":"Tim Visher","fromEmail":"tim.visher@gmail.com","sentAt":"2008-12-22T21:16:40Z","receivedAt":"2008-12-22T21:16:40Z","isPatch":false,"sender":{"key":"tim.visher@gmail.com","avatar":"https://gravatar.com/avatar/98307ce54bcac1a46b5d845827d5386e2a27895ff08790cdd3877ad527760575?d=mp&s=160"},"body":"On Mon, Dec 22, 2008 at 4:11 PM, Junio C Hamano <gitster@pobox.com> wrote:\n\n> Do you mean during a conflicted merge resolution you would want to check\n> their version out of the index and declare that it is the merge result?\n\nSure.  Let me try to be a bit clearer.\n\nI was developing on a feature branch and now want to merge back into\nthe master branch.  Unfortunately, a binary file somewhat central to\nthe development effort was changed between the the feature branch and\nthe master branch and now there is a conflict.  Obviously, I can't fix\nthe conflict via markers or something like that because it's a binary\nfile, and I know that I want the feature branch's version of the file,\nnot the one that it is in conflict with.  How would I just select the\nstage3 version of the file and add that to the index?\n\n-- \n\nIn Christ,\n\nTimmy V.\n\nhttp://burningones.com/\nhttp://five.sentenc.es/ - Spend less time on e-mail\n"},{"id":"98566","messageId":"7vd4fjhlf8.fsf@gitster.siamese.dyndns.org","threadId":"16838","inReplyTo":"c115fd3c0812221316y24ce0c7q29807cd349a99e83@mail.gmail.com","subject":"Re: 'Theirs' merge between branches on a binary file.","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2008-12-22T22:52:59Z","receivedAt":"2008-12-22T22:52:59Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Tim Visher\" <tim.visher@gmail.com> writes:\n\n> On Mon, Dec 22, 2008 at 4:11 PM, Junio C Hamano <gitster@pobox.com> wrote:\n>\n>> Do you mean during a conflicted merge resolution you would want to check\n>> their version out of the index and declare that it is the merge result?\n>\n> Sure.\n\nThat sounds like \"git checkout --theirs\"...\n"},{"id":"98567","messageId":"c115fd3c0812221458q3444cbcai7ab1716b9195ad08@mail.gmail.com","threadId":"16838","inReplyTo":"7vd4fjhlf8.fsf@gitster.siamese.dyndns.org","subject":"Re: 'Theirs' merge between branches on a binary file.","fromName":"Tim Visher","fromEmail":"tim.visher@gmail.com","sentAt":"2008-12-22T22:58:39Z","receivedAt":"2008-12-22T22:58:39Z","isPatch":false,"sender":{"key":"tim.visher@gmail.com","avatar":"https://gravatar.com/avatar/98307ce54bcac1a46b5d845827d5386e2a27895ff08790cdd3877ad527760575?d=mp&s=160"},"body":"On Mon, Dec 22, 2008 at 5:52 PM, Junio C Hamano <gitster@pobox.com> wrote:\n\n> That sounds like \"git checkout --theirs\"...\n\nI'm sorry, Junio.  I don't mean to be dense but I can't find that in\nthe docs and when I execute it it comes back as an unknown command.\nPerhaps you could just point me to the relevant man page?  This seems\nlike such a fundamental operation, I just don't understand why there\nisn't something like a `git resolve`.\n\nThanks for your help!\n\n-- \n\nIn Christ,\n\nTimmy V.\n\nhttp://burningones.com/\nhttp://five.sentenc.es/ - Spend less time on e-mail\n"},{"id":"98569","messageId":"7v3agfhk8b.fsf@gitster.siamese.dyndns.org","threadId":"16838","inReplyTo":"c115fd3c0812221458q3444cbcai7ab1716b9195ad08@mail.gmail.com","subject":"Re: 'Theirs' merge between branches on a binary file.","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2008-12-22T23:18:44Z","receivedAt":"2008-12-22T23:18:44Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Tim Visher\" <tim.visher@gmail.com> writes:\n\n> On Mon, Dec 22, 2008 at 5:52 PM, Junio C Hamano <gitster@pobox.com> wrote:\n>\n>> That sounds like \"git checkout --theirs\"...\n>\n> I'm sorry, Junio.  I don't mean to be dense but I can't find that in\n> the docs and when I execute it it comes back as an unknown command.\n\nHmph, I meant to point you at:\n\n    http://www.kernel.org/pub/software/scm/git/docs/git-checkout.html\n\nI think you can use \"git checkout-index --stage=3 path\" if your git is\nolder than that one with the option.\n\nv1.6.0.1-15-g38901a4 (checkout --ours/--theirs: allow checking out one\nside of a conflicting merge, 2008-08-30) introduced the feature.\n"},{"id":"98608","messageId":"c115fd3c0812230605x369af9c0n372db761fa11ce39@mail.gmail.com","threadId":"16838","inReplyTo":"7v3agfhk8b.fsf@gitster.siamese.dyndns.org","subject":"Re: 'Theirs' merge between branches on a binary file.","fromName":"Tim Visher","fromEmail":"tim.visher@gmail.com","sentAt":"2008-12-23T14:05:17Z","receivedAt":"2008-12-23T14:05:17Z","isPatch":false,"sender":{"key":"tim.visher@gmail.com","avatar":"https://gravatar.com/avatar/98307ce54bcac1a46b5d845827d5386e2a27895ff08790cdd3877ad527760575?d=mp&s=160"},"body":"On Mon, Dec 22, 2008 at 6:18 PM, Junio C Hamano <gitster@pobox.com> wrote:\n\n> Hmph, I meant to point you at:\n>\n>    http://www.kernel.org/pub/software/scm/git/docs/git-checkout.html\n\nAh, yes.  There it is. :)\n\n> I think you can use \"git checkout-index --stage=3 path\" if your git is\n> older than that one with the option.\n>\n> v1.6.0.1-15-g38901a4 (checkout --ours/--theirs: allow checking out one\n> side of a conflicting merge, 2008-08-30) introduced the feature.\n\nApparently this was added, at least to the docs, only in the latest\nrelease?  That's kind of weird A) because the tag indicates 1.6.0.1,\nnot 0.6, and B) It's a pretty trivial operation in other VCSes.\nHmm... Maybe I'll try to updated the docs to make this feature a\nlittle more visible.\n\nAnyway, the checkout-index command does indeed work in the older\nversion.  That's kind of what I was looking for.  I'm now working on\ncompiling git under cygwin as the latest version cygwin installs for\nyou is 0.4!\n\nThanks for your help!\n\n-- \n\nIn Christ,\n\nTimmy V.\n\nhttp://burningones.com/\nhttp://five.sentenc.es/ - Spend less time on e-mail\n"},{"id":"98636","messageId":"49512E9A.5040902@lsrfire.ath.cx","threadId":"16838","inReplyTo":"c115fd3c0812230605x369af9c0n372db761fa11ce39@mail.gmail.com","subject":"Re: 'Theirs' merge between branches on a binary file.","fromName":"René Scharfe","fromEmail":"rene.scharfe@lsrfire.ath.cx","sentAt":"2008-12-23T18:31:54Z","receivedAt":"2008-12-23T18:31:54Z","isPatch":false,"sender":{"key":"l.s.r@web.de","avatar":"https://avatars.githubusercontent.com/u/26122331?v=4"},"body":"Tim Visher schrieb:\n> I'm now working on\n> compiling git under cygwin as the latest version cygwin installs for\n> you is 0.4!\n\nHave you seen msysgit (http://code.google.com/p/msysgit/), the easy\nroute to git on Windows?  It has all you need to check out and compile\nthe latest version of git.\n\nRené\n"},{"id":"98844","messageId":"c115fd3c0812280914p61e3db34vb033f30b1e04da33@mail.gmail.com","threadId":"16838","inReplyTo":"49512E9A.5040902@lsrfire.ath.cx","subject":"Re: 'Theirs' merge between branches on a binary file.","fromName":"Tim Visher","fromEmail":"tim.visher@gmail.com","sentAt":"2008-12-28T17:14:54Z","receivedAt":"2008-12-28T17:14:54Z","isPatch":false,"sender":{"key":"tim.visher@gmail.com","avatar":"https://gravatar.com/avatar/98307ce54bcac1a46b5d845827d5386e2a27895ff08790cdd3877ad527760575?d=mp&s=160"},"body":"On Tue, Dec 23, 2008 at 1:31 PM, René Scharfe\n<rene.scharfe@lsrfire.ath.cx> wrote:\n\n> Have you seen msysgit (http://code.google.com/p/msysgit/), the easy\n> route to git on Windows?  It has all you need to check out and compile\n> the latest version of git.\n\nI have seen msysgit.  I haven't spent too much time with it mainly\nbecause I'm in denial that I have to work with Windows all day at\nwork.  I'm going to have to look into it I think when I attempt to get\nmy team onto git in a little less than a month.\n\n-- \n\nIn Christ,\n\nTimmy V.\n\nhttp://burningones.com/\nhttp://five.sentenc.es/ - Spend less time on e-mail\n"}]}