Skip to content

Commit

Permalink
color-words: expand docs with precise semantics
Browse files Browse the repository at this point in the history
Signed-off-by: Thomas Rast <[email protected]>
Signed-off-by: Junio C Hamano <[email protected]>
  • Loading branch information
trast authored and gitster committed Jan 17, 2009
1 parent bf82940 commit c4b252c
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions Documentation/diff-options.txt
Original file line number Diff line number Diff line change
Expand Up @@ -91,12 +91,17 @@ endif::git-format-patch[]
Turn off colored diff, even when the configuration file
gives the default to color output.

--color-words[=regex]::
Show colored word diff, i.e. color words which have changed.
--color-words[=<regex>]::
Show colored word diff, i.e., color words which have changed.
By default, words are separated by whitespace.
+
Optionally, you can pass a regular expression that tells Git what the
words are that you are looking for; The default is to interpret any
stretch of non-whitespace as a word.
When a <regex> is specified, every non-overlapping match of the
<regex> is considered a word. Anything between these matches is
considered whitespace and ignored(!) for the purposes of finding
differences. You may want to append `|[^[:space:]]` to your regular
expression to make sure that it matches all non-whitespace characters.
A match that contains a newline is silently truncated(!) at the
newline.

--no-renames::
Turn off rename detection, even when the configuration
Expand Down

0 comments on commit c4b252c

Please sign in to comment.