From: Junio C Hamano Date: Mon, 6 Nov 2017 04:11:27 +0000 (+0900) Subject: Merge branch 'cn/diff-indent-no-longer-is-experimental' X-Git-Tag: v2.16.0-rc0~173 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/662ac3b3a8a16fd749b598c85c4d8bfea5bb208e?hp=-c Merge branch 'cn/diff-indent-no-longer-is-experimental' Doc update. * cn/diff-indent-no-longer-is-experimental: diff: --indent-heuristic is no longer experimental --- 662ac3b3a8a16fd749b598c85c4d8bfea5bb208e diff --combined Documentation/diff-options.txt index a88c76741e,f028689f7c..dd0dba5b1d --- a/Documentation/diff-options.txt +++ b/Documentation/diff-options.txt @@@ -63,7 -63,12 +63,12 @@@ ifndef::git-format-patch[ Synonym for `-p --raw`. endif::git-format-patch[] - include::diff-heuristic-options.txt[] + --indent-heuristic:: + Enable the heuristic that shift diff hunk boundaries to make patches + easier to read. This is the default. + + --no-indent-heuristic:: + Disable the indent heuristic. --minimal:: Spend extra time to make sure the smallest possible @@@ -231,40 -236,6 +236,40 @@@ ifdef::git-diff[ endif::git-diff[] It is the same as `--color=never`. +--color-moved[=]:: + Moved lines of code are colored differently. +ifdef::git-diff[] + It can be changed by the `diff.colorMoved` configuration setting. +endif::git-diff[] + The defaults to 'no' if the option is not given + and to 'zebra' if the option with no mode is given. + The mode must be one of: ++ +-- +no:: + Moved lines are not highlighted. +default:: + Is a synonym for `zebra`. This may change to a more sensible mode + in the future. +plain:: + Any line that is added in one location and was removed + in another location will be colored with 'color.diff.newMoved'. + Similarly 'color.diff.oldMoved' will be used for removed lines + that are added somewhere else in the diff. This mode picks up any + moved line, but it is not very useful in a review to determine + if a block of code was moved without permutation. +zebra:: + Blocks of moved text of at least 20 alphanumeric characters + are detected greedily. The detected blocks are + painted using either the 'color.diff.{old,new}Moved' color or + 'color.diff.{old,new}MovedAlternative'. The change between + the two colors indicates that a new block was detected. +dimmed_zebra:: + Similar to 'zebra', but additional dimming of uninteresting parts + of moved code is performed. The bordering lines of two adjacent + blocks are considered interesting, the rest is uninteresting. +-- + --word-diff[=]:: Show a word diff, using the to delimit changed words. By default, words are delimited by whitespace; see