##// END OF EJS Templates
git: fix parsing of git mode change + rename diffs...
Mads Kiilerich -
r5590:2bf5e873 stable
parent child Browse files
Show More
@@ -160,11 +160,11 b' class DiffProcessor(object):'
160 # has already been split on this:
160 # has already been split on this:
161 # ^diff[ ]--git
161 # ^diff[ ]--git
162 [ ]a/(?P<a_path>.+?)[ ]b/(?P<b_path>.+?)\n
162 [ ]a/(?P<a_path>.+?)[ ]b/(?P<b_path>.+?)\n
163 (?:^old[ ]mode[ ](?P<old_mode>\d+)\n
164 ^new[ ]mode[ ](?P<new_mode>\d+)(?:\n|$))?
163 (?:^similarity[ ]index[ ](?P<similarity_index>\d+)%\n
165 (?:^similarity[ ]index[ ](?P<similarity_index>\d+)%\n
164 ^rename[ ]from[ ](?P<rename_from>.+)\n
166 ^rename[ ]from[ ](?P<rename_from>.+)\n
165 ^rename[ ]to[ ](?P<rename_to>.+)(?:\n|$))?
167 ^rename[ ]to[ ](?P<rename_to>.+)(?:\n|$))?
166 (?:^old[ ]mode[ ](?P<old_mode>\d+)\n
167 ^new[ ]mode[ ](?P<new_mode>\d+)(?:\n|$))?
168 (?:^new[ ]file[ ]mode[ ](?P<new_file_mode>.+)(?:\n|$))?
168 (?:^new[ ]file[ ]mode[ ](?P<new_file_mode>.+)(?:\n|$))?
169 (?:^deleted[ ]file[ ]mode[ ](?P<deleted_file_mode>.+)(?:\n|$))?
169 (?:^deleted[ ]file[ ]mode[ ](?P<deleted_file_mode>.+)(?:\n|$))?
170 (?:^index[ ](?P<a_blob_id>[0-9A-Fa-f]+)
170 (?:^index[ ](?P<a_blob_id>[0-9A-Fa-f]+)
@@ -2,3 +2,9 b' diff --git a/work-horus.xls b/file.xls'
2 similarity index 100%
2 similarity index 100%
3 rename from work-horus.xls
3 rename from work-horus.xls
4 rename to file.xls
4 rename to file.xls
5 diff --git a/files/var/www/favicon.ico b/files/var/www/favicon.ico/DEFAULT
6 old mode 100644
7 new mode 100755
8 similarity index 100%
9 rename from files/var/www/favicon.ico
10 rename to files/var/www/favicon.ico/DEFAULT
@@ -133,7 +133,14 b' DIFF_FIXTURES = {'
133 {'added': 0,
133 {'added': 0,
134 'deleted': 0,
134 'deleted': 0,
135 'binary': True,
135 'binary': True,
136 'ops': {RENAMED_FILENODE: 'file renamed from work-horus.xls to file.xls'}})
136 'ops': {RENAMED_FILENODE: 'file renamed from work-horus.xls to file.xls'}}),
137 ('files/var/www/favicon.ico/DEFAULT',
138 'R',
139 {'added': 0,
140 'binary': True,
141 'deleted': 0,
142 'ops': {4: 'file renamed from files/var/www/favicon.ico to files/var/www/favicon.ico/DEFAULT',
143 6: 'modified file chmod 100644 => 100755'}})
137 ],
144 ],
138 'git_diff_mod_single_binary_file.diff': [
145 'git_diff_mod_single_binary_file.diff': [
139 ('US Warszawa.jpg', 'M',
146 ('US Warszawa.jpg', 'M',
General Comments 0
You need to be logged in to leave comments. Login now