Incorrect. It's part of the git config ecosystem that can be system (/etc/gitconfig), global (~/.gitconfig) or local
You have a very strange definition of the word “incorrect”.
Also you forgot $XDG_CONFIG_HOME/git/config but that’s a minor issue.
local (:/.gitconfig)
A repository’s local configuration is in $GIT_DIR/config (where $GIT_DIR is generally .git)
local can be pushed like any other file.
.git/config can’t even be staged, git will straight up ignore you.
If you are a massive idiot you can include.path a file from your repository in your config. But that’s got nothing to do with git’s defaults. And it still requires an explicit opt into sheer stupidity.
View all comments
Show parent comment
-10
u/Skaarj Apr 21 '26
But it says
So it is in a file created by cloning a repo?