git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Charles Bailey <charles@hashpling.org>
To: David Aguilar <davvid@gmail.com>
Cc: Felipe Contreras <felipe.contreras@gmail.com>, git@vger.kernel.org
Subject: Re: [PATCH 2/2] mergetool: run prompt only if guessed tool
Date: Tue, 22 Apr 2014 07:01:20 +0100	[thread overview]
Message-ID: <20140422060120.GA10198@hashpling.org> (raw)
In-Reply-To: <20140422045951.GA60610@gmail.com>

On Mon, Apr 21, 2014 at 09:59:52PM -0700, David Aguilar wrote:
> [Cc:ing Charles in case he has an opinion, this behavior dates back to the original MT]
> 
> On Sun, Apr 20, 2014 at 07:17:34PM -0500, Felipe Contreras wrote:
> > It's annoying to see the prompt:
> > 
> >   Hit return to start merge resolution tool (foo):
> > 
> > Every time the user does 'git mergetool' even if the user already
> > configured 'foo' as the wanted tool.
> > 
> > Display this prompt only when the user hasn't explicitly configured a
> > tool.
> 
> I agree this is probably helpful.
> Most users I've met end up configuring mergetool.prompt=false.

>From my memory, the reason that we choose to prompt by default is to
help new users or users who have just changed their choice of mergetool.

Because we never use the exit code of the tool to determine whether a
tool "worked", if we don't prompt and the tool fails (bad custom
command, requires X when no X available, etc.) then we'll repeatedly run
the command for all paths requiring resolution leading to, potentially,
a lot of trace with whatever error the tool might happen to report.

We prompt by default to give users a chance to abort the mergetool
session at the first opportunity that they see that the configured tool
is not working.

Personally, I leave mergetool.prompt unset (default true) because one
extra click in a complex merge resolution is relatively low overhead and
to catch myself when I forget that I'm in a no-X environment.

I glanced at the patch and it seems to subvert this intent for users
who have  configured a merge tool. Is my understanding correct?

  reply	other threads:[~2014-04-22  6:01 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-21  0:17 [PATCH 0/2] Simple default fixes for v2.0 Felipe Contreras
2014-04-21  0:17 ` [PATCH 1/2] merge: enable defaulttoupstream by default Felipe Contreras
2014-04-22 19:53   ` Junio C Hamano
2014-04-21  0:17 ` [PATCH 2/2] mergetool: run prompt only if guessed tool Felipe Contreras
2014-04-22  4:59   ` David Aguilar
2014-04-22  6:01     ` Charles Bailey [this message]
2014-04-22  6:24       ` Felipe Contreras
2014-04-22  6:55         ` Charles Bailey
2014-04-22  6:53           ` Felipe Contreras
2014-04-22  7:30             ` Charles Bailey
2014-04-22  7:56               ` Felipe Contreras
2014-04-23  7:56                 ` Charles Bailey
2014-04-23 17:07                   ` Junio C Hamano
2014-04-24 18:30                     ` Junio C Hamano
2014-04-22 17:19     ` Junio C Hamano
2014-04-23  7:58       ` David Aguilar
2014-04-23 16:52         ` Junio C Hamano
2014-04-22 17:32     ` Junio C Hamano
2014-04-22 19:55       ` 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=20140422060120.GA10198@hashpling.org \
    --to=charles@hashpling.org \
    --cc=davvid@gmail.com \
    --cc=felipe.contreras@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.
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 NNTP newsgroup(s).