Show More
@@ -201,7 +201,7 b' class eolfile(object):' | |||||
201 | data = ctx[f].data() |
|
201 | data = ctx[f].data() | |
202 | if (target == "to-lf" and "\r\n" in data |
|
202 | if (target == "to-lf" and "\r\n" in data | |
203 | or target == "to-crlf" and singlelf.search(data)): |
|
203 | or target == "to-crlf" and singlelf.search(data)): | |
204 |
failed.append(( |
|
204 | failed.append((f, target, str(ctx))) | |
205 | break |
|
205 | break | |
206 | return failed |
|
206 | return failed | |
207 |
|
207 | |||
@@ -244,7 +244,7 b' def _checkhook(ui, repo, node, headsonly' | |||||
244 | if failed: |
|
244 | if failed: | |
245 | eols = {'to-lf': 'CRLF', 'to-crlf': 'LF'} |
|
245 | eols = {'to-lf': 'CRLF', 'to-crlf': 'LF'} | |
246 | msgs = [] |
|
246 | msgs = [] | |
247 |
for |
|
247 | for f, target, node in sorted(failed): | |
248 | msgs.append(_(" %s in %s should not have %s line endings") % |
|
248 | msgs.append(_(" %s in %s should not have %s line endings") % | |
249 | (f, node, eols[target])) |
|
249 | (f, node, eols[target])) | |
250 | raise error.Abort(_("end-of-line check failed:\n") + "\n".join(msgs)) |
|
250 | raise error.Abort(_("end-of-line check failed:\n") + "\n".join(msgs)) |
@@ -206,13 +206,13 b' Test multiple files/revisions output' | |||||
206 | adding file changes |
|
206 | adding file changes | |
207 | added 3 changesets with 3 changes to 2 files (+1 heads) |
|
207 | added 3 changesets with 3 changes to 2 files (+1 heads) | |
208 | error: pretxnchangegroup hook failed: end-of-line check failed: |
|
208 | error: pretxnchangegroup hook failed: end-of-line check failed: | |
|
209 | b.txt in fbcf9b1025f5 should not have CRLF line endings | |||
209 | d.txt in a7040e68714f should not have CRLF line endings |
|
210 | d.txt in a7040e68714f should not have CRLF line endings | |
210 | b.txt in fbcf9b1025f5 should not have CRLF line endings |
|
|||
211 | transaction abort! |
|
211 | transaction abort! | |
212 | rollback completed |
|
212 | rollback completed | |
213 | abort: end-of-line check failed: |
|
213 | abort: end-of-line check failed: | |
|
214 | b.txt in fbcf9b1025f5 should not have CRLF line endings | |||
214 | d.txt in a7040e68714f should not have CRLF line endings |
|
215 | d.txt in a7040e68714f should not have CRLF line endings | |
215 | b.txt in fbcf9b1025f5 should not have CRLF line endings |
|
|||
216 | [255] |
|
216 | [255] | |
217 |
|
217 | |||
218 | $ cd .. |
|
218 | $ cd .. |
General Comments 0
You need to be logged in to leave comments.
Login now