Show More
@@ -9,7 +9,7 b' from node import nullid, nullrev, short,' | |||||
9 | from i18n import _ |
|
9 | from i18n import _ | |
10 | import mdiff, error, util, scmutil, subrepo, patch, encoding, phases |
|
10 | import mdiff, error, util, scmutil, subrepo, patch, encoding, phases | |
11 | import match as matchmod |
|
11 | import match as matchmod | |
12 |
import |
|
12 | import os, errno, stat | |
13 | import obsolete as obsmod |
|
13 | import obsolete as obsmod | |
14 | import repoview |
|
14 | import repoview | |
15 | import fileset |
|
15 | import fileset | |
@@ -595,19 +595,17 b' class changectx(basectx):' | |||||
595 | def walk(self, match): |
|
595 | def walk(self, match): | |
596 | '''Generates matching file names.''' |
|
596 | '''Generates matching file names.''' | |
597 |
|
597 | |||
598 |
# |
|
598 | # Wrap match.bad method to have message with nodeid | |
599 | match = copy.copy(match) |
|
|||
600 | oldbad = match.bad |
|
|||
601 | def bad(fn, msg): |
|
599 | def bad(fn, msg): | |
602 | # The manifest doesn't know about subrepos, so don't complain about |
|
600 | # The manifest doesn't know about subrepos, so don't complain about | |
603 | # paths into valid subrepos. |
|
601 | # paths into valid subrepos. | |
604 | if any(fn == s or fn.startswith(s + '/') |
|
602 | if any(fn == s or fn.startswith(s + '/') | |
605 | for s in self.substate): |
|
603 | for s in self.substate): | |
606 | return |
|
604 | return | |
607 |
|
|
605 | match.bad(fn, _('no such file in rev %s') % self) | |
608 | match.bad = bad |
|
|||
609 |
|
606 | |||
610 | return self._manifest.walk(match) |
|
607 | m = matchmod.badmatch(match, bad) | |
|
608 | return self._manifest.walk(m) | |||
611 |
|
609 | |||
612 | def matches(self, match): |
|
610 | def matches(self, match): | |
613 | return self.walk(match) |
|
611 | return self.walk(match) |
General Comments 0
You need to be logged in to leave comments.
Login now