git/list[1] front-page[2] threads[3] people[4] search[5] about
 

git/path.c - order of accessing ~/.gitconfig

From
MMadhu <enometh@meer.net>
Date
Sep 18, 2013, 14:40 UTC
Message-ID
<20130918.201006.407922449.enometh@meer.net>
* commit 21cf32279120799a766d22416be7d82d9ecfbd04
|
| Author: Huynh Khoi Nguyen Nguyen <Huynh-Khoi-Nguyen.Nguyen@ensimag.imag.fr>
| Date:   Fri Jun 22 11:03:23 2012 +0200
|
|    config: read (but not write) from $XDG_CONFIG_HOME/git/config file
|
|    Teach git to read the "gitconfig" information from a new location,
|    $XDG_CONFIG_HOME/git/config; this allows the user to avoid
|    cluttering $HOME with many per-application configuration files.
|
|    In the order of reading, this file comes between the global
|    configuration file (typically $HOME/.gitconfig) and the system wide
|    configuration file (typically /etc/gitconfig).

However git/config.c (git_config_early) commit accesses xdg_config before user_config. So the comments and documentation are inconsistent with the code.

[This looks like an intentional bug, I spotted it when commenting out
 the accesses to files under ~/.config.  (protip: chmod 000 ~/.config helps
 identify and blacklist NWO "apps" and now git started complaining) ---Madhu
Next: Matthieu Moy
Message 1 of 3 in “git/path.c - order of accessing ~/.gitconfig”
  1. MadhuSep 18, 2013
  2. Matthieu MoySep 18, 2013
  3. MadhuSep 18, 2013

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.