author | J. Bruce Fields <bfields@citi.umich.edu> | |
Sun, 16 Sep 2007 22:49:00 +0000 (18:49 -0400) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Mon, 17 Sep 2007 09:18:44 +0000 (02:18 -0700) | ||
commit | d7416ecac8508367a8ac35ab74ef09b7707d0c4b | |
tree | 7a53da669ad42caf3999d73c8cf0056e7659aef4 | tree | snapshot |
parent | ece7b74903007cee8d280573647243d46a6f3a95 | commit | diff |
git-apply: fix whitespace stripping
The algorithm isn't right here: it accumulates any set of 8 spaces into
tabs even if they're separated by tabs, so
<four spaces><tab><four spaces><tab>
is converted to
<tab><tab><tab>
when it should be just
<tab><tab>
So teach git-apply that a tab hides any group of less than 8 previous
spaces in a row.
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
The algorithm isn't right here: it accumulates any set of 8 spaces into
tabs even if they're separated by tabs, so
<four spaces><tab><four spaces><tab>
is converted to
<tab><tab><tab>
when it should be just
<tab><tab>
So teach git-apply that a tab hides any group of less than 8 previous
spaces in a row.
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin-apply.c | diff | blob | history |