summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2017-08-23 14:13:08 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2017-08-23 14:13:08 -0700
commit76be4487f08d40bd1dba0d5b0dcbd2513ca26e8c (patch)
treebc815e24db637b9cbfc3e48c98d3b549f8a8b352
parentMerge branch 'kw/rebase-progress' (diff)
parentdoc: clarify "config --bool" behaviour with empty string (diff)
downloadtgif-76be4487f08d40bd1dba0d5b0dcbd2513ca26e8c.tar.xz
Merge branch 'ah/doc-empty-string-is-false'
Doc update. * ah/doc-empty-string-is-false: doc: clarify "config --bool" behaviour with empty string
-rw-r--r--Documentation/config.txt10
-rw-r--r--Documentation/git.txt3
2 files changed, 7 insertions, 6 deletions
diff --git a/Documentation/config.txt b/Documentation/config.txt
index d5c9c4cab6..478b9431e0 100644
--- a/Documentation/config.txt
+++ b/Documentation/config.txt
@@ -216,15 +216,15 @@ boolean::
synonyms are accepted for 'true' and 'false'; these are all
case-insensitive.
- true;; Boolean true can be spelled as `yes`, `on`, `true`,
- or `1`. Also, a variable defined without `= <value>`
+ true;; Boolean true literals are `yes`, `on`, `true`,
+ and `1`. Also, a variable defined without `= <value>`
is taken as true.
- false;; Boolean false can be spelled as `no`, `off`,
- `false`, or `0`.
+ false;; Boolean false literals are `no`, `off`, `false`,
+ `0` and the empty string.
+
When converting value to the canonical form using `--bool` type
-specifier; 'git config' will ensure that the output is "true" or
+specifier, 'git config' will ensure that the output is "true" or
"false" (spelled in lowercase).
integer::
diff --git a/Documentation/git.txt b/Documentation/git.txt
index 7dd5e03280..6e3a6767e5 100644
--- a/Documentation/git.txt
+++ b/Documentation/git.txt
@@ -75,7 +75,8 @@ example the following invocations are equivalent:
Note that omitting the `=` in `git -c foo.bar ...` is allowed and sets
`foo.bar` to the boolean true value (just like `[foo]bar` would in a
config file). Including the equals but with an empty value (like `git -c
-foo.bar= ...`) sets `foo.bar` to the empty string.
+foo.bar= ...`) sets `foo.bar` to the empty string which ` git config
+--bool` will convert to `false`.
--exec-path[=<path>]::
Path to wherever your core Git programs are installed.