changeset 28017 | d3f1b7ee5e70 |
parent 27595 | 9e2d01707e71 |
child 28128 | 92f2c69ee5a5 |
--- a/mercurial/match.py Wed Feb 03 18:59:35 2016 +0000 +++ b/mercurial/match.py Fri Feb 05 21:09:32 2016 -0800 @@ -334,13 +334,13 @@ m.bad = badfn return m -class narrowmatcher(match): +class subdirmatcher(match): """Adapt a matcher to work on a subdirectory only. The paths are remapped to remove/insert the path as needed: >>> m1 = match('root', '', ['a.txt', 'sub/b.txt']) - >>> m2 = narrowmatcher('sub', m1) + >>> m2 = subdirmatcher('sub', m1) >>> bool(m2('a.txt')) False >>> bool(m2('b.txt'))