All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
From: Jeff King <peff@peff.net>
To: Junio C Hamano <gitster@pobox.com>
Cc: Gregory Anders <greg@gpanders.com>, git@vger.kernel.org
Subject: Re: Syntax for specifying a command in git config
Date: Tue, 11 May 2021 20:32:40 -0400	[thread overview]
Message-ID: <YJsiKDNbKclFU00b@coredump.intra.peff.net> (raw)
In-Reply-To: <xmqqo8dgj2vk.fsf@gitster.g>

On Wed, May 12, 2021 at 07:56:47AM +0900, Junio C Hamano wrote:

> > IMHO this is a good path forward. There's a thread from a few months ago
> > which talks about this idea:
> >
> >   https://lore.kernel.org/git/YCvotU6KVruFuf9%2F@coredump.intra.peff.net/
> >
> > There's some back and forth, and I'm not sure if I convinced Junio in
> > the end. But certainly a patch would be a good way to restart the
> > conversation. :)
> 
> The argument is not just about configuration but applies equally to
> its command line argument "--smtp-server=<what>", right?  I think it
> makes sense in both of these places.  I further wonder if we should
> allow not just a single token, but supplying an initial few arguments,
> too, e.g.
> 
> 	git send-email --smtp-server="/usr/bin/env msmtp"
> 	git send-email --smtp-server="!my-msa --emulate-sendmail"

Yes, the patch under discussion does apply to both the command-line
option and the config option (and I agree it should).

I didn't think about arguments, but you're right that may be a useful
feature. And if done via the shell, as brian suggested elsewhere, would
be more consistent with other parts of Git using "!" syntax.

It does make things a little weird in that:

  git send-email --smtp-server='/path/to/my-sendmail foo'

and

  git send-email --smtp-server '!my-sendmail foo'

behave differently (the first does not work; it looks for an executable
with a space in the name).

-Peff

  reply	other threads:[~2021-05-12  0:32 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-11 18:07 Syntax for specifying a command in git config Gregory Anders
2021-05-11 18:17 ` Jeff King
2021-05-11 22:56   ` Junio C Hamano
2021-05-12  0:32     ` Jeff King [this message]
2021-05-12  3:25       ` 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=YJsiKDNbKclFU00b@coredump.intra.peff.net \
    --to=peff@peff.net \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=greg@gpanders.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.