public inbox for git@vger.kernel.org 
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox•com>
To: "Gondek\, Andreas" <Andreas.Gondek@dwpbank•de>
Cc: "git\@vger.kernel.org" <git@vger•kernel.org>
Subject: Re: Getting the full path of a conflicting file within a custom merge driver?
Date: Mon, 01 Jun 2015 09:46:23 -0700	[thread overview]
Message-ID: <xmqqr3pv74ww.fsf@gitster.dls.corp.google.com> (raw)
In-Reply-To: <D8780C527EB1E642B3150E6D705B46D468837861@DWPWHMS531.dwpbank.local> (Andreas Gondek's message of "Mon, 1 Jun 2015 15:46:44 +0000")

"Gondek, Andreas" <Andreas.Gondek@dwpbank•de> writes:

> I'm wondering if there is no option to find out the full path of a
> conflicting file from within a custom merge driver? If I understand
> this correctly, Git only provides the name of the 3 temporary local
> files and the size of the limiter. But is there any possibility to get
> the path of the file via a Git command, that I can run from within the
> merge driver? Maybe as part of the repository's status?

Short answer is "no", as the merge driver interface was originally
designed for a backend that can do its job with only the contents of
the three variants without any other information.  Imagine the
interface to things like "merge" from the RCS suite where it takes
three variants as the input---for them, the same three-tuple of
original, mine and theirs contents should merge to identical result
no matter where in the working tree the conflicts happened.

Having said that, I do not think it is unreasonable to feed more
information to external merge driver, perhaps by adding a new
environment variable GIT_MERGE_CONFLICTED_PATH exported when the
driver is run, or something.

  reply	other threads:[~2015-06-01 16:46 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-01 15:46 Getting the full path of a conflicting file within a custom merge driver? Gondek, Andreas
2015-06-01 16:46 ` Junio C Hamano [this message]
2015-06-02 10:57   ` AW: " Gondek, Andreas
2015-06-02 17:47     ` Junio C Hamano
2015-06-04 22:11       ` Re*: " Junio C Hamano
2015-06-05  5:56         ` AW: " Gondek, Andreas
2015-06-05  8:07           ` Christian Couder
2015-06-05  8:38             ` Christian Couder
2015-06-05 15:19           ` AW: " Junio C Hamano

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=xmqqr3pv74ww.fsf@gitster.dls.corp.google.com \
    --to=gitster@pobox$(echo .)com \
    --cc=Andreas.Gondek@dwpbank$(echo .)de \
    --cc=git@vger$(echo .)kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox