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

Feature request: read git config from parent directory

From
DDDominique Dumont <dod@debian.org>
Date
Dec 8, 2016, 19:49 UTC
Message-ID
<3881793.6JIRvg1BPW@ylum>
Hello

I use the same machine for work and open-source contribution. In both cases, I deal with a lot of repositories. Depending on whether I commit for work or open-source activities, I must use a different mail address. I used to setup work address for each work repo in git local config, but this is no longer practical.

Since I use different directories for work and open-source, would it be possible for git to read irs config also from parent directories ? I.e. setup git to read config from ./.git/config then ../.gitconfig, ../../gitconfig until global ~/.gitconfig.

All the best
-- 
 https://github.com/dod38fr/   -o- http://search.cpan.org/~ddumont/
http://ddumont.wordpress.com/  -o-   irc: dod at irc.debian.org
Next: Duy Nguyen
Message 1 of 3 in “Feature request: read git config from parent directory”
  1. Dominique DumontDec 8, 2016
  2. Duy NguyenDec 9, 2016
  3. Dominique DumontDec 10, 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.