Re: [PATCH 1/3] --dirstat: Document shortcomings compared to --stat or regular diff

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Johan Herland <johan@xxxxxxxxxxx> writes:

> diff --git a/Documentation/diff-options.txt b/Documentation/diff-options.txt
> index c93124b..25e48c4 100644
> --- a/Documentation/diff-options.txt
> +++ b/Documentation/diff-options.txt
> @@ -72,6 +72,11 @@ endif::git-format-patch[]
>  	a cut-off percent (3% by default) are not shown. The cut-off percent
>  	can be set with `--dirstat=<limit>`. Changes in a child directory are not
>  	counted for the parent directory, unless `--cumulative` is used.
> ++
> +Note that `--dirstat` does not use the regular diff machinery to calculate
> +the changes (rather it is based on the rename detection machinery). Therefore,
> +`--dirstat` may skip some changes that `--stat` does not skip. For example,
> +rearranging the lines in a file will not be detected by `--dirstat`.

Be positive: s/will not be detected/is not considered to be a change/,
perhaps.  Also "it is based on the rename detection machinery" is
describing an implementation detail without helping the end users.

Try to rephrase what Linus explained when he said "it is very much on
purpose".  Perhaps like this?

    Note that the `--dirstat` option computes the changes while ignoring
    pure code movements within a file.  In other words, rearranging lines
    in a file is not counted as a change.

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]