All of lore.kernel.org
 help / color / mirror / Atom feed
From: Delilah Ashley Wu <delilahwu@linux.microsoft.com>
To: Ben Knoble <ben.knoble@gmail.com>
Cc: Junio C Hamano <gitster@pobox.com>,
	Nils Fahldieck <nils@fahldieck.de>,
	 git@vger.kernel.org
Subject: Re: [BUG] git config --global: doc and behaviour disagree when ~/.gitconfig and XDG config file coexist
Date: Thu, 13 Aug 2026 16:07:08 +1000	[thread overview]
Message-ID: <an1dekUM_fsM_l8d-delilahwu@linux.microsoft.com> (raw)
In-Reply-To: <336EEC18-98D3-4068-8C5C-476749959814@gmail.com>

On Fri, Jul 31, 2026 at 09:14:07AM +1000, Ben Knoble wrote:
>> Le 31 juil. 2026 à 05:35, Junio C Hamano <gitster@pobox.com> a écrit :
>> Nils Fahldieck <nils@fahldieck.de> writes:
>>> 2. The reading claim is outright wrong.
>>> 
>>>   The docs say --global reads from BOTH files.  The code reads from
>>>   ONE.  git_global_config() selects a winner and frees the other
>>>   path.  There is no code path under --global that reads both files.
>> 
>> The documentation needs to be corrected, I think.
> 
> Agreed based on recent thread <20260720113402.0dc16abe@frustcomp.hnjs.home.arpa>
> (subject « git config: unintuitive behavior with - -global and - -no-includes »

A previous thread [1] said this behavior could be a bug. So, last year,
I submitted a patch series [2] to align behavior with documentation,
changing `git config` to read from both files. We gave time for the
community to comment on whether we should change the behavior or the
documentation, but there weren't any strong opinions [3]. The only
responses were a correction to my cover letter and a technical review of
my patches.

Since then, I've addressed most of the review feedback. I have a draft
v2 series [4] almost ready for reroll. I only work on it during "side
project time" [5] at my workplace, but I'll try to have v2 ready soon
for further discussion/review.

[1] https://lore.kernel.org/git/xmqqmt5lezi3.fsf@gitster.g/
[2] https://lore.kernel.org/git/pull.1938.git.1760058849.gitgitgadget@gmail.com/
[3] https://lore.kernel.org/git/xmqqtsysfakt.fsf@gitster.g/
[4] https://github.com/gitgitgadget/git/pull/2196
[5] https://en.wikipedia.org/wiki/Side_project_time

      parent reply	other threads:[~2026-08-13  6:07 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-30 18:18 [BUG] git config --global: doc and behaviour disagree when ~/.gitconfig and XDG config file coexist Nils Fahldieck
2026-07-30 20:24 ` Junio C Hamano
2026-07-31  0:14   ` Ben Knoble
2026-07-31 18:19     ` Nils Fahldieck
2026-08-13  6:07     ` Delilah Ashley Wu [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=an1dekUM_fsM_l8d-delilahwu@linux.microsoft.com \
    --to=delilahwu@linux.microsoft.com \
    --cc=ben.knoble@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=nils@fahldieck.de \
    /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.