[lug] How do I get the merge I want?

Davide Del Vento davide.del.vento at gmail.com
Tue Mar 4 19:36:54 MST 2014


I've succeeded convincing "git diff" to provide the git-fancy-colored
output for two regular, unknown-to-git files. So I guess if you can
convince git diff to provide what you want, you can use my trick and see if
you can combine the two. Would that help?

If so, tomorrow I will post mine (I don't remember what I did, I scripted
it somewhere)


On Tue, Mar 4, 2014 at 7:17 PM, Jeffrey S. Haemer
<jeffrey.haemer at gmail.com>wrote:

> Dave,
>
>
>> And yes, I could put the two versions into git in different branches and
>>> then call "git merge." :-)
>>>
>>
>> Could you?  What would be the common ancestor?  I think git would just
>> show you a diff (granted in fancy git style, which might also be what you
>> want).
>>
>
> Granted, but someone forgot to tell "git diff" that it wouldn't work. :-)
>
> Try this:
>
> mkdir hello
> cd hello
> git flow init -d
> git checkout -b 1
> for i in a{1..5} {6..10} b{11..15}; do echo $i; done > myfile
> git add .; git commit -am"branch 1"
> git checkout develop
> git checkout -b 2
> for i in x{1..5} {6..10} y{11..15}; do echo $i; done > myfile
> git add .; git commit -am"branch 2"
> git diff 1 2
>
>
> --
> Jeffrey Haemer <jeffrey.haemer at gmail.com>
> 720-837-8908 [cell], http://seejeffrun.blogspot.com [blog],
> http://www.youtube.com/user/goyishekop [vlog]
> *פרייהייט? דאס איז יאַנג דינען וואָרט.*
>
> _______________________________________________
> Web Page:  http://lug.boulder.co.us
> Mailing List: http://lists.lug.boulder.co.us/mailman/listinfo/lug
> Join us on IRC: irc.hackingsociety.org port=6667 channel=#hackingsociety
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lug.boulder.co.us/pipermail/lug/attachments/20140304/57f251a6/attachment.html>


More information about the LUG mailing list