Show More
@@ -206,6 +206,7 b' pypats = [' | |||||
206 | (r'\.debug\(\_', "don't mark debug messages for translation"), |
|
206 | (r'\.debug\(\_', "don't mark debug messages for translation"), | |
207 | (r'\.strip\(\)\.split\(\)', "no need to strip before splitting"), |
|
207 | (r'\.strip\(\)\.split\(\)', "no need to strip before splitting"), | |
208 | (r'^\s*except\s*:', "warning: naked except clause", r'#.*re-raises'), |
|
208 | (r'^\s*except\s*:', "warning: naked except clause", r'#.*re-raises'), | |
|
209 | (r':\n( )*( ){1,3}[^ ]', "must indent 4 spaces"), | |||
209 | ], |
|
210 | ], | |
210 | # warnings |
|
211 | # warnings | |
211 | [ |
|
212 | [ |
@@ -74,7 +74,7 b' def shouldtransform(node):' | |||||
74 | 'setattr' in sggparent or \ |
|
74 | 'setattr' in sggparent or \ | |
75 | 'encode' in sggparent or \ |
|
75 | 'encode' in sggparent or \ | |
76 | 'decode' in sggparent: |
|
76 | 'decode' in sggparent: | |
77 |
|
|
77 | return False | |
78 |
|
78 | |||
79 | return True |
|
79 | return True | |
80 |
|
80 |
@@ -121,7 +121,7 b' def lfconvert(ui, src, dest, *pats, **op' | |||||
121 | shutil.rmtree(rdst.root) |
|
121 | shutil.rmtree(rdst.root) | |
122 |
|
122 | |||
123 | def _addchangeset(ui, rsrc, rdst, ctx, revmap): |
|
123 | def _addchangeset(ui, rsrc, rdst, ctx, revmap): | |
124 | # Convert src parents to dst parents |
|
124 | # Convert src parents to dst parents | |
125 | parents = _convertparents(ctx, revmap) |
|
125 | parents = _convertparents(ctx, revmap) | |
126 |
|
126 | |||
127 | # Generate list of changed files |
|
127 | # Generate list of changed files | |
@@ -506,7 +506,7 b' def _updatelfile(repo, lfdirstate, lfile' | |||||
506 | # because otherwise the largefile will get reverted. But for commit's |
|
506 | # because otherwise the largefile will get reverted. But for commit's | |
507 | # sake, we have to mark the file as unclean. |
|
507 | # sake, we have to mark the file as unclean. | |
508 | if getattr(repo, "_isrebasing", False): |
|
508 | if getattr(repo, "_isrebasing", False): | |
509 | lfdirstate.normallookup(lfile) |
|
509 | lfdirstate.normallookup(lfile) | |
510 | else: |
|
510 | else: | |
511 | lfdirstate.normal(lfile) |
|
511 | lfdirstate.normal(lfile) | |
512 | elif state == 'r': |
|
512 | elif state == 'r': |
@@ -667,9 +667,9 b' def overridepull(orig, ui, repo, source=' | |||||
667 | repo._isrebasing = True |
|
667 | repo._isrebasing = True | |
668 | try: |
|
668 | try: | |
669 | if opts.get('update'): |
|
669 | if opts.get('update'): | |
670 |
|
|
670 | del opts['update'] | |
671 |
|
|
671 | ui.debug('--update and --rebase are not compatible, ignoring ' | |
672 |
|
|
672 | 'the update flag\n') | |
673 | del opts['rebase'] |
|
673 | del opts['rebase'] | |
674 | cmdutil.bailifchanged(repo) |
|
674 | cmdutil.bailifchanged(repo) | |
675 | origpostincoming = commands.postincoming |
|
675 | origpostincoming = commands.postincoming |
@@ -666,9 +666,9 b' def revsettransplanted(repo, subset, x):' | |||||
666 | Transplanted changesets in set, or all transplanted changesets. |
|
666 | Transplanted changesets in set, or all transplanted changesets. | |
667 | """ |
|
667 | """ | |
668 | if x: |
|
668 | if x: | |
669 | s = revset.getset(repo, subset, x) |
|
669 | s = revset.getset(repo, subset, x) | |
670 | else: |
|
670 | else: | |
671 | s = subset |
|
671 | s = subset | |
672 | return [r for r in s if repo[r].extra().get('transplant_source')] |
|
672 | return [r for r in s if repo[r].extra().get('transplant_source')] | |
673 |
|
673 | |||
674 | def kwtransplanted(repo, ctx, **args): |
|
674 | def kwtransplanted(repo, ctx, **args): |
@@ -4499,7 +4499,7 b' def phase(ui, repo, *revs, **opts):' | |||||
4499 | try: |
|
4499 | try: | |
4500 | # set phase |
|
4500 | # set phase | |
4501 | if not revs: |
|
4501 | if not revs: | |
4502 |
|
|
4502 | raise util.Abort(_('empty revision set')) | |
4503 | nodes = [repo[r].node() for r in revs] |
|
4503 | nodes = [repo[r].node() for r in revs] | |
4504 | olddata = repo._phasecache.getphaserevs(repo)[:] |
|
4504 | olddata = repo._phasecache.getphaserevs(repo)[:] | |
4505 | phases.advanceboundary(repo, targetphase, nodes) |
|
4505 | phases.advanceboundary(repo, targetphase, nodes) | |
@@ -5442,7 +5442,7 b' def summary(ui, repo, **opts):' | |||||
5442 | # current bookmark not in parent ctx marks |
|
5442 | # current bookmark not in parent ctx marks | |
5443 | pass |
|
5443 | pass | |
5444 | for m in marks: |
|
5444 | for m in marks: | |
5445 | ui.write(' ' + m, label='log.bookmark') |
|
5445 | ui.write(' ' + m, label='log.bookmark') | |
5446 | ui.write('\n', label='log.bookmark') |
|
5446 | ui.write('\n', label='log.bookmark') | |
5447 |
|
5447 | |||
5448 | st = list(repo.status(unknown=True))[:6] |
|
5448 | st = list(repo.status(unknown=True))[:6] |
@@ -169,7 +169,7 b' def _runcatch(req):' | |||||
169 | try: # usually it is in the form (errno, strerror) |
|
169 | try: # usually it is in the form (errno, strerror) | |
170 | reason = inst.reason.args[1] |
|
170 | reason = inst.reason.args[1] | |
171 | except (AttributeError, IndexError): |
|
171 | except (AttributeError, IndexError): | |
172 |
|
|
172 | # it might be anything, for example a string | |
173 | reason = inst.reason |
|
173 | reason = inst.reason | |
174 | ui.warn(_("abort: error: %s\n") % reason) |
|
174 | ui.warn(_("abort: error: %s\n") % reason) | |
175 | elif util.safehasattr(inst, "args") and inst.args[0] == errno.EPIPE: |
|
175 | elif util.safehasattr(inst, "args") and inst.args[0] == errno.EPIPE: |
@@ -272,7 +272,7 b' class localrepository(object):' | |||||
272 | return bookmarks.readcurrent(self) |
|
272 | return bookmarks.readcurrent(self) | |
273 |
|
273 | |||
274 | def _writebookmarks(self, marks): |
|
274 | def _writebookmarks(self, marks): | |
275 | bookmarks.write(self) |
|
275 | bookmarks.write(self) | |
276 |
|
276 | |||
277 | def bookmarkheads(self, bookmark): |
|
277 | def bookmarkheads(self, bookmark): | |
278 | name = bookmark.split('@', 1)[0] |
|
278 | name = bookmark.split('@', 1)[0] |
@@ -634,7 +634,7 b' class patchfile(object):' | |||||
634 | if self.mode is None: |
|
634 | if self.mode is None: | |
635 | self.mode = (False, False) |
|
635 | self.mode = (False, False) | |
636 | if self.missing: |
|
636 | if self.missing: | |
637 |
|
|
637 | self.ui.warn(_("unable to find '%s' for patching\n") % self.fname) | |
638 |
|
638 | |||
639 | self.hash = {} |
|
639 | self.hash = {} | |
640 | self.dirty = 0 |
|
640 | self.dirty = 0 | |
@@ -1630,9 +1630,9 b' def diff(repo, node1=None, node2=None, m' | |||||
1630 | if opts.git or opts.upgrade: |
|
1630 | if opts.git or opts.upgrade: | |
1631 | copy = copies.pathcopies(ctx1, ctx2) |
|
1631 | copy = copies.pathcopies(ctx1, ctx2) | |
1632 |
|
1632 | |||
1633 |
difffn |
|
1633 | def difffn(opts, losedata): | |
1634 |
|
|
1634 | return trydiff(repo, revs, ctx1, ctx2, modified, added, removed, | |
1635 |
|
|
1635 | copy, getfilectx, opts, losedata, prefix) | |
1636 | if opts.upgrade and not opts.git: |
|
1636 | if opts.upgrade and not opts.git: | |
1637 | try: |
|
1637 | try: | |
1638 | def losedata(fn): |
|
1638 | def losedata(fn): |
General Comments 0
You need to be logged in to leave comments.
Login now