Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/commands.py @ 6578:f242d3684f83
walk: begin refactoring badmatch handling
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Mon, 12 May 2008 11:37:07 -0500 |
parents | 626cb86a6523 |
children | 0159b7a36184 |
comparison
equal
deleted
inserted
replaced
6577:569761919450 | 6578:f242d3684f83 |
---|---|
30 | 30 |
31 rejected = None | 31 rejected = None |
32 exacts = {} | 32 exacts = {} |
33 names = [] | 33 names = [] |
34 for src, abs, rel, exact in cmdutil.walk(repo, pats, opts, | 34 for src, abs, rel, exact in cmdutil.walk(repo, pats, opts, |
35 badmatch=util.always): | 35 badmatch=lambda x,y: True): |
36 if exact: | 36 if exact: |
37 if ui.verbose: | 37 if ui.verbose: |
38 ui.status(_('adding %s\n') % rel) | 38 ui.status(_('adding %s\n') % rel) |
39 names.append(abs) | 39 names.append(abs) |
40 exacts[abs] = 1 | 40 exacts[abs] = 1 |
1694 else: | 1694 else: |
1695 node = None | 1695 node = None |
1696 | 1696 |
1697 ret = 1 | 1697 ret = 1 |
1698 for src, abs, rel, exact in cmdutil.walk(repo, pats, opts, node=node, | 1698 for src, abs, rel, exact in cmdutil.walk(repo, pats, opts, node=node, |
1699 badmatch=util.always, | 1699 badmatch=lambda x,y: True, |
1700 default='relglob'): | 1700 default='relglob'): |
1701 if src == 'b': | 1701 if src == 'b': |
1702 continue | 1702 continue |
1703 if not node and abs not in repo.dirstate: | 1703 if not node and abs not in repo.dirstate: |
1704 continue | 1704 continue |