From: "Jeremy Ramer" <jdramer@gmail.com>
To: git@vger.kernel.org
Subject: merge conflict diff
Date: Thu, 3 Apr 2008 08:13:04 -0600 [thread overview]
Message-ID: <b9fd99020804030713n3c1a2602t847e8a132f8ccd06@mail.gmail.com> (raw)
Hi,
I am trying to figure out how to quickly diff two source files that
led to a merge conflict. When a conflict occurs the command
# git diff
performs a diff -cc, but I would like to compare the files before any
merging takes place so I can decide if I should just take all the
changes from one of the sources.
i.e. take the changes from the merging branch:
# git checkout-index -f -u --stage=3 foo
# git add foo
So far I am thinking of
# git checkout-index --stage=2 --temp foo
# git checkout-index --stage=3 --temp foo
# git diff .merge_x1 .merge_x2
Are there any built-in ways to accomplish this? I'd like to be able to
build a script that can quickly start the diff based on the file name
I provide.
Thanks!
Jeremy
next reply other threads:[~2008-04-03 14:13 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-03 14:13 Jeremy Ramer [this message]
2008-04-03 14:26 ` merge conflict diff Jeff King
2008-04-03 14:58 ` Jeremy Ramer
2008-04-03 16:48 ` Matthieu Moy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=b9fd99020804030713n3c1a2602t847e8a132f8ccd06@mail.gmail.com \
--to=jdramer@gmail.com \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).