On Wed, Feb 10, 2010 at 12:57 AM, Petr Baudis <pasky@xxxxxxx> wrote: > Hi! > > On Wed, Feb 10, 2010 at 12:45:44AM +0100, Christian MICHON wrote: >> I'm performing many merges between developpers branches these days, >> most of them not yielding into conflicts. (understand: simple merges) >> >> All is good, but sometimes, I would like to really like what has been changed. >> >> As I do not systematically do this "git merge --no-commit --stat >> <list_to_merge>" and then fire "git gui" to inspect the diffs before >> the real commit, I'm wondering: how could I do this using some >> plumbing ? >> >> Right now, I've tried the obvious git log -c -p, git show -u --cc, but >> since the merge are simple merges, I cannot get any diff output. I >> believe this is by construction. >> >> Any hints ? > > I'm not sure if there is any clever switch for this, but I usually > just use one of > > git diff mergecommit^1 mergecommit > git diff mergecommit^2 mergecommit > > depending on which parent I want the diff against. If you always do your > merges as "on mainline, merging in a topic" without fast-forwarding, > diff against the first parent will be probably the right one and you can > simply use: > > git diff mergecommit^ mergecommit > Hi Petr, unfortunately it does not ouput anything :-( the diff is empty, again... I'm fiddling now with "git checkout -f <that-commit>", and I'm faking an "amend last commit" using "git gui". With this dirty trick, I get the same diff I would have gotten from git gui with a merge --no-commit. Thanks for suggesting ! -- Christian -- http://detaolb.sourceforge.net/, a linux distribution for Qemu with Git inside ! -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html