Skip to content

Commit 4bb9eb5

Browse files
peffgitster
authored andcommitted
doc/git-config: explain --file instead of referring to GIT_CONFIG
The explanation for the --file option only refers to GIT_CONFIG. This redirection to an environment variable is confusing, but doubly so because the description of GIT_CONFIG is out of date. Let's describe --file from scratch, detailing both the reading and writing behavior as we do for other similar options like --system, etc. Signed-off-by: Jeff King <[email protected]> Reviewed-by: Taylor Blau <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent ebf3c04 commit 4bb9eb5

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

Documentation/git-config.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,13 @@ See also <<FILES>>.
143143

144144
-f config-file::
145145
--file config-file::
146-
Use the given config file instead of the one specified by GIT_CONFIG.
146+
For writing options: write to the specified file rather than the
147+
repository `.git/config`.
148+
+
149+
For reading options: read only from the specified file rather than from all
150+
available files.
151+
+
152+
See also <<FILES>>.
147153

148154
--blob blob::
149155
Similar to `--file` but use the given blob instead of a file. E.g.

0 commit comments

Comments
 (0)