Commit 66d9558f authored by Jonas Bernoulli's avatar Jonas Bernoulli

magit-diff-wash-diffstat: Handle renames

But ignore the special-case of file-names that contain " => ".
Handling that properly would require the use of "-z", which would
require changes all over the place and this code is going to be
refactored soon anyway.

Fixes #3440.
parent bcd633af
......@@ -1694,7 +1694,12 @@ section or a child thereof."
(magit-insert-heading)
(let (files)
(while (looking-at "^[-0-9]+\t[-0-9]+\t\\(.+\\)$")
(push (magit-decode-git-path (match-string 1)) files)
(push (magit-decode-git-path
(let ((f (match-string 1)))
(if (string-match " => " f)
(substring f (match-end 0))
f)))
files)
(magit-delete-line))
(setq files (nreverse files))
(while (looking-at magit-diff-statline-re)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment