git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Eric Sunshine <sunshine@sunshineco.com>
To: Nicolas Morey-Chaisemartin <NMoreyChaisemartin@suse.de>
Cc: Git List <git@vger.kernel.org>
Subject: Re: [PATCH] tag: add --edit option
Date: Thu, 1 Feb 2018 05:56:34 -0500	[thread overview]
Message-ID: <CAPig+cTEoM3qYRN6j=zSVv1LPx_ggVuxqTMMK0SpjtYEqOiBMA@mail.gmail.com> (raw)
In-Reply-To: <bbc03595-cb31-63b8-3f4c-cfa04bb9ff27@suse.de>

On Thu, Feb 1, 2018 at 5:43 AM, Nicolas Morey-Chaisemartin
<NMoreyChaisemartin@suse.de> wrote:
> Le 01/02/2018 à 11:34, Nicolas Morey-Chaisemartin a écrit :
>> Le 01/02/2018 à 11:16, Eric Sunshine a écrit :
>>> A little below this change is where launch_editor() is actually
>>> invoked. If it fails for some reason, it prints:
>>>
>>>     Please supply the message using either -m or -F option.
>>>
>>> which seems a bit counterintuitive if the user *did* specify one of
>>> those options along with --edit. I wonder if that message needs to be
>>> adjusted.
>>>
>> Yes I'll fix this.
> I just checked what commit.c does and it seems to behave as my patch:
>         if (launch_editor(git_path_commit_editmsg(), NULL, env.argv)) {
>             fprintf(stderr,
>             _("Please supply the message using either -m or -F option.\n"));
>
> To be honest the message is not that clear either.
> If I'm reading launch_editor right most (or all) its falire are du to a failure to launch the editor or the editor crashed/exited with an error.
> In this case, I wouldn't advise the user to use -m or -F but to fix its editor.

Indeed, I also looked at the implementation of launch_editor(), and my
"wondering" about whether the message needed adjustment was just that.
The message seems somewhat counterintuitive in this case, but I didn't
necessarily have a better suggestion. A valid response, therefore,
might be to punt on it and leave that change for the future, or
perhaps take it on as a second patch which adjusts the message in both
commands. I don't have strong feelings about it at this time.

  reply	other threads:[~2018-02-01 10:56 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-01  9:49 [PATCH] tag: add --edit option Nicolas Morey-Chaisemartin
2018-02-01 10:16 ` Eric Sunshine
2018-02-01 10:34   ` Nicolas Morey-Chaisemartin
2018-02-01 10:43     ` Nicolas Morey-Chaisemartin
2018-02-01 10:56       ` Eric Sunshine [this message]
2018-02-01 14:05         ` Nicolas Morey-Chaisemartin
2018-02-01 15:25 ` Ramsay Jones

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='CAPig+cTEoM3qYRN6j=zSVv1LPx_ggVuxqTMMK0SpjtYEqOiBMA@mail.gmail.com' \
    --to=sunshine@sunshineco.com \
    --cc=NMoreyChaisemartin@suse.de \
    --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).