Skip to content

Commit

Permalink
Documentation: git diff --check respects core.whitespace
Browse files Browse the repository at this point in the history
Fix documentation on "git diff --check" by adopting the description from
"git apply --whitespace".

Signed-off-by: Christof Krüger <git@christof-krueger.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Christof Krüger authored and Junio C Hamano committed Jun 22, 2011
1 parent a598ded commit 4f83039
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions Documentation/diff-options.txt
Original file line number Diff line number Diff line change
Expand Up @@ -194,10 +194,14 @@ endif::git-format-patch[]

ifndef::git-format-patch[]
--check::
Warn if changes introduce trailing whitespace
or an indent that uses a space before a tab. Exits with
non-zero status if problems are found. Not compatible with
--exit-code.
Warn if changes introduce whitespace errors. What are
considered whitespace errors is controlled by `core.whitespace`
configuration. By default, trailing whitespaces (including
lines that solely consist of whitespaces) and a space character
that is immediately followed by a tab character inside the
initial indent of the line are considered whitespace errors.
Exits with non-zero status if problems are found. Not compatible
with --exit-code.
endif::git-format-patch[]

--full-index::
Expand Down

0 comments on commit 4f83039

Please sign in to comment.