Git Mailing List Archive mirror
 help / color / mirror / Atom feed
From: "Priedhorsky, Reid" <reidpr@lanl.gov>
To: "git@vger.kernel.org" <git@vger.kernel.org>
Cc: "brian m. carlson" <sandals@crustytoothpaste.net>,
	Junio C Hamano <gitster@pobox.com>
Subject: Re: bug? subprocesses can use wrong Git if $PATH is unset
Date: Wed, 7 Jun 2023 17:43:00 +0000	[thread overview]
Message-ID: <52BEE66B-934F-449F-A9BA-75B61A64A989@lanl.gov> (raw)
In-Reply-To: <xmqqwn0l72bg.fsf@gitster.g>


> On Jun 2, 2023, at 7:38 PM, Junio C Hamano <gitster@pobox.com> wrote:
> 
> "brian m. carlson" <sandals@crustytoothpaste.net> writes:
> 
>> On 2023-06-02 at 16:14:47, Priedhorsky, Reid wrote:
>>> Hello Brian,
>>> 
>>> I do wonder if the behavior would be worth documenting, e.g. at
>>> https://urldefense.com/v3/__https://git-scm.com/book/en/v2/Git-Internals-Environment-Variables__;!!Bt8fGhp8LhKGRg!CTLDK9n1pGJTODDrapV9r_JrypUCk5A_v4w7bz6GgCTz8_sg91kpz2ID1NRptCjG2bUMiJ6ftC-PlM4$ ,
>>> where Git’s relationship to $HOME is also documented. I would be happy
>>> to submit a pull request.
>> 
>> I don't think it's necessary, since it's expected behaviour for me, but
>> I am not the only person on this list, and perhaps others would
>> appreciate a patch.
> 
> I tend to agree that it is an expected behaviour.  In addition,
> unsetting PATH is not something people deliberately do every day
> without understanding its implications, so I would rather not see us
> add "if you do this esteric thing, this would happen" for them.
> 
> Thanks.

Thank you; that sounds like a consensus.

To be clear though, we didn’t unset $PATH on purpose. We found unexpected behavior and tracked it down to a bug that cleared the environment, including $PATH.

Thanks,
Reid

—
he/his

      reply	other threads:[~2023-06-07 17:43 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-01 22:21 bug? subprocesses can use wrong Git if $PATH is unset Priedhorsky, Reid
2023-06-02  0:35 ` brian m. carlson
2023-06-02 16:14   ` Priedhorsky, Reid
2023-06-02 20:20     ` brian m. carlson
2023-06-03  1:38       ` Junio C Hamano
2023-06-07 17:43         ` Priedhorsky, Reid [this message]

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=52BEE66B-934F-449F-A9BA-75B61A64A989@lanl.gov \
    --to=reidpr@lanl.gov \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=sandals@crustytoothpaste.net \
    /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 read-only IMAP folder(s) and NNTP newsgroup(s).