Skip to content
This repository was archived by the owner on Nov 9, 2017. It is now read-only.

Commit ec84e06

Browse files
jrngitster
authored andcommitted
config doc: remove confusion about relative GIT_DIR from FILES section
From the FILES section of the git-config(1) manual: $GIT_DIR/config:: Repository specific configuration file. (The filename is of course relative to the repository root, not the working directory.) That's confusing because $GIT_DIR really is relative to the working directory. $ GIT_DIR=.git GIT_EDITOR='pwd; echo editing' $ export GIT_DIR GIT_EDITOR $ git config --edit --local /home/jrn/src/git/Documentation editing .git/config It turns out that the comment is a remnant from older days when the heading said ".git/config" (which is indeed relative to the top of the worktree). It was only when the heading was changed to refer more precisely to <git dir>/config (see v1.5.3.2~18, AsciiDoc tweak to avoid leading dot, 2007-09-14) that the parenthesis stopped making sense. Remove it. Signed-off-by: Jonathan Nieder <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent c464918 commit ec84e06

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

Documentation/git-config.txt

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -198,9 +198,7 @@ If not set explicitly with '--file', there are three files where
198198
'git config' will search for configuration options:
199199

200200
$GIT_DIR/config::
201-
Repository specific configuration file. (The filename is
202-
of course relative to the repository root, not the working
203-
directory.)
201+
Repository specific configuration file.
204202

205203
~/.gitconfig::
206204
User-specific configuration file. Also called "global"

0 commit comments

Comments
 (0)