diff --git a/mercurial/util.py b/mercurial/util.py --- a/mercurial/util.py +++ b/mercurial/util.py @@ -397,19 +397,23 @@ def _matcher(canonroot, cwd, names, inc, inc - patterns to include exc - patterns to exclude head - a regex to prepend to patterns to control whether a match is rooted + dflt_pat - if a pattern in names has no explicit type, assume this one + src - where these patterns came from (e.g. .hgignore) a pattern is one of: - 'glob:' - 're:' - 'path:' - 'relglob:' - 'relpath:' - 'relre:' - '' + 'glob:' - a glob relative to cwd + 're:' - a regular expression + 'path:' - a path relative to canonroot + 'relglob:' - an unrooted glob (*.c matches C files in all dirs) + 'relpath:' - a path relative to cwd + 'relre:' - a regexp that doesn't have to match the start of a name + '' - one of the cases above, selected by the dflt_pat argument returns: a 3-tuple containing - - list of explicit non-pattern names passed in + - list of roots (places where one should start a recursive walk of the fs); + this often matches the explicit non-pattern names passed in, but also + includes the initial part of glob: patterns that has no glob characters - a bool match(filename) function - a bool indicating if any patterns were passed in