path: root/Documentation/git-config.txt
diff options
authorMatthieu Moy <>2009-12-30 16:51:53 (GMT)
committerJunio C Hamano <>2009-12-31 20:19:38 (GMT)
commit1349484e341a3ec2ba02a86c8fbd97ea9dc8c756 (patch)
tree5c2d753daa7234da64de974c1badcc4973b35e79 /Documentation/git-config.txt
parent902f235378cb2b2f6dd5dd664b9630c95321f0ae (diff)
builtin-config: add --path option doing ~ and ~user expansion.
395de250 (Expand ~ and ~user in core.excludesfile, commit.template) introduced a C function git_config_pathname, doing ~/ and ~user/ expansion. This patch makes the feature available to scripts with 'git config --get --path'. Signed-off-by: Matthieu Moy <> Signed-off-by: Junio C Hamano <>
Diffstat (limited to 'Documentation/git-config.txt')
1 files changed, 11 insertions, 3 deletions
diff --git a/Documentation/git-config.txt b/Documentation/git-config.txt
index f68b198..2632928 100644
--- a/Documentation/git-config.txt
+++ b/Documentation/git-config.txt
@@ -37,11 +37,12 @@ existing values that match the regexp are updated or unset. If
you want to handle the lines that do *not* match the regex, just
prepend a single exclamation mark in front (see also <<EXAMPLES>>).
-The type specifier can be either '--int' or '--bool', which will make
+The type specifier can be either '--int' or '--bool', to make
'git-config' ensure that the variable(s) are of the given type and
convert the value to the canonical form (simple decimal number for int,
-a "true" or "false" string for bool). If no type specifier is passed,
-no checks or transformations are performed on the value.
+a "true" or "false" string for bool), or '--path', which does some
+path expansion (see '--path' below). If no type specifier is passed, no
+checks or transformations are performed on the value.
The file-option can be one of '--system', '--global' or '--file'
which specify where the values will be read from or written to.
@@ -136,6 +137,13 @@ See also <<FILES>>.
'git-config' will ensure that the output matches the format of
either --bool or --int, as described above.
+ 'git-config' will expand leading '{tilde}' to the value of
+ '$HOME', and '{tilde}user' to the home directory for the
+ specified user. This option has no effect when setting the
+ value (but you can use 'git config bla {tilde}/' from the
+ command line to let your shell do the expansion).
For all options that output values and/or keys, always