From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS53758 23.128.96.0/24 X-Spam-Status: No, score=-3.9 required=3.0 tests=AWL,BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, SPF_HELO_PASS,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by dcvr.yhbt.net (Postfix) with ESMTP id 4C0B71F5AE for ; Wed, 12 May 2021 00:50:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230005AbhELAvH (ORCPT ); Tue, 11 May 2021 20:51:07 -0400 Received: from cloud.peff.net ([104.130.231.41]:51660 "EHLO cloud.peff.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229637AbhELAvH (ORCPT ); Tue, 11 May 2021 20:51:07 -0400 Received: (qmail 25270 invoked by uid 109); 12 May 2021 00:49:59 -0000 Received: from Unknown (HELO peff.net) (10.0.1.2) by cloud.peff.net (qpsmtpd/0.94) with ESMTP; Wed, 12 May 2021 00:49:59 +0000 Authentication-Results: cloud.peff.net; auth=none Received: (qmail 30781 invoked by uid 111); 12 May 2021 00:50:00 -0000 Received: from coredump.intra.peff.net (HELO sigill.intra.peff.net) (10.0.0.2) by peff.net (qpsmtpd/0.94) with (TLS_AES_256_GCM_SHA384 encrypted) ESMTPS; Tue, 11 May 2021 20:50:00 -0400 Authentication-Results: peff.net; auth=none Date: Tue, 11 May 2021 20:49:58 -0400 From: Jeff King To: Gregory Anders Cc: "brian m. carlson" , git@vger.kernel.org, Junio C Hamano Subject: Re: [PATCH v5] git-send-email: use ! to indicate relative path to command Message-ID: References: <20210511204044.69047-1-greg@gpanders.com> <20210511234935.65147-1-greg@gpanders.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org On Tue, May 11, 2021 at 06:45:58PM -0600, Gregory Anders wrote: > > > Elsewhere we use the ! syntax we invoke the shell, and I would suggest > > > that we do the same here. That means we'll get PATH functionality by > > > default and we'll let people do a modicum of scripting if they like. > > > > Thanks for bringing that up. I agree it makes things more consistent > > with other uses of "!", and certainly it's more flexible. It does > > introduce an inconsistency with the absolute-path form, as I mentioned > > in https://lore.kernel.org/git/YJsiKDNbKclFU00b@coredump.intra.peff.net/. > > > > I don't know if that's a show-stopper or not. Certainly the > > documentation can explain the difference, but it's nice to keep the > > rules as simple as possible. > > > > (My gut feeling is that consistency with other "!" places is more > > important than consistency with the absolute-path form). > > > > -Peff > > We already have sendemail.smtpServerOption to add options: > > [sendemail] > smtpServer = !msmtp > smtpServerOption = -f > smtpServerOption = greg@gpanders.com > > I agree that it's not the prettiest and it's a little annoying to have to > specify the option multiple times, but I thought it worth mentioning before > considering another way to do the same thing. Thanks for bringing that up. I agree that does give back some of the flexibility, but it is inconsistent with most other parts of Git. > I also am curious what other's thoughts are on Felipe's suggestion to add a > sendemail.program option, which would altogether remove the need to further > overload sendemail.smtpServer: > https://lore.kernel.org/git/609b0017a323b_6064920888@natae.notmuch/ > > IMO if we want to add the capability to run an arbitrary shell command as > the smtpServer, this makes more sense to add as a dedicated > sendemail.program option that has that functionality baked right in: > > [sendemail] > program = "msmtp -f greg@gpanders.com" Our mails just crossed, but yeah, I think that would be a fine direction. -Peff