Skip to content

Commit 136f6bf

Browse files
authored
Clarify explanation of configuring core.whitespace
1 parent 24d22be commit 136f6bf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

book/08-customizing-git/sections/config.asc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -422,12 +422,12 @@ The three that are disabled by default but can be turned on are `indent-with-non
422422

423423
You can tell Git which of these you want enabled by setting `core.whitespace` to the values you want on or off, separated by commas.
424424
You can disable settings by either leaving them out of the setting string or prepending a `-` in front of the value.
425-
For example, if you want all but `cr-at-eol` to be set, you can do this:
425+
For example, if you want all but `cr-at-eol` to be set, you can do this (with `trailing-space` being a short-hand to cover both `blank-at-eol` and `blank-at-eof`):
426426

427427
[source,console]
428428
----
429429
$ git config --global core.whitespace \
430-
trailing-space,space-before-tab,indent-with-non-tab
430+
trailing-space,space-before-tab,indent-with-non-tab,tab-in-indent
431431
----
432432

433433
Git will detect these issues when you run a `git diff` command and try to color them so you can possibly fix them before you commit.

0 commit comments

Comments
 (0)