##// END OF EJS Templates
diff: use second filename for --stat reporting on git patches (issue4221)
Matt Mackall -
r20972:4e2fb0ad default
parent child Browse files
Show More
@@ -1859,7 +1859,7 b' def diffstatdata(lines):'
1859 # set numbers to 0 anyway when starting new file
1859 # set numbers to 0 anyway when starting new file
1860 adds, removes, isbinary = 0, 0, False
1860 adds, removes, isbinary = 0, 0, False
1861 if line.startswith('diff --git a/'):
1861 if line.startswith('diff --git a/'):
1862 filename = gitre.search(line).group(1)
1862 filename = gitre.search(line).group(2)
1863 elif line.startswith('diff -r'):
1863 elif line.startswith('diff -r'):
1864 # format: "diff -r ... -r ... filename"
1864 # format: "diff -r ... -r ... filename"
1865 filename = diffre.search(line).group(1)
1865 filename = diffre.search(line).group(1)
@@ -1853,7 +1853,7 b' Test --patch and --stat with --follow an'
1853 | date: Thu Jan 01 00:00:00 1970 +0000
1853 | date: Thu Jan 01 00:00:00 1970 +0000
1854 | summary: copy a b
1854 | summary: copy a b
1855 |
1855 |
1856 | a | 0
1856 | b | 0
1857 | 1 files changed, 0 insertions(+), 0 deletions(-)
1857 | 1 files changed, 0 insertions(+), 0 deletions(-)
1858 |
1858 |
1859
1859
@@ -1886,7 +1886,7 b' Test --patch and --stat with --follow an'
1886 | date: Thu Jan 01 00:00:00 1970 +0000
1886 | date: Thu Jan 01 00:00:00 1970 +0000
1887 | summary: copy a b
1887 | summary: copy a b
1888 |
1888 |
1889 | a | 0
1889 | b | 0
1890 | 1 files changed, 0 insertions(+), 0 deletions(-)
1890 | 1 files changed, 0 insertions(+), 0 deletions(-)
1891 |
1891 |
1892 o changeset: 0:f8035bb17114
1892 o changeset: 0:f8035bb17114
General Comments 0
You need to be logged in to leave comments. Login now