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

gitconfig includes

From
Eli Barzilay <eli@barzilay.org>
Date
Nov 29, 2016, 19:40 UTC
Message-ID
<CALO-gutW80d6RLdXAtYA2m2GWOchAjNNPy3YCsr31_fCss512g@mail.gmail.com>
I just noticed something weird: if I have this in my ~/.gitconfig:
    [x]
      x = global
    [include]
      path = .gitconfig.more
and .gitconfig.more has
    [x]
      x = more
then I get:
1. git config x.x                      =>  more
2. git config --global x.x             =>  global
3. git config --global --includes x.x  =>  more

The first works as I expected. The second surprised me, since I took "--global" to mean "the global file and stuff it includes" (that's my understanding of the description of `include`). The third is fine, but it made me even more surprised at the second, especially since the man blurb on --includes says "Defaults to on."...

So this is at least a documentation issue, though I hope that #2 is a bug and that it *should* return "more"...?

-- 
                   ((x=>x(x))(x=>x(x)))                  Eli Barzilay:
                   http://barzilay.org/                  Maze is Life!
Next: Junio C Hamano
Message 1 of 8 in “gitconfig includes”
  1. Eli BarzilayNov 29, 2016
  2. Junio C HamanoNov 29, 2016
  3. Eli BarzilayNov 29, 2016
  4. Jeff KingNov 29, 2016
  5. Junio C HamanoNov 29, 2016
  6. Eli BarzilayNov 30, 2016
  7. Jeff KingNov 30, 2016
  8. Eli BarzilayNov 30, 2016

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.