Mercurial > hg
changeset 29318:2572bb2e06f8
largefiles: rename match_ to matchmod import in overrides
author | liscju <piotr.listkiewicz@gmail.com> |
---|---|
date | Thu, 12 May 2016 11:48:39 +0200 |
parents | 5ec25534ef4f |
children | cc497d2830b0 |
files | hgext/largefiles/overrides.py |
diffstat | 1 files changed, 10 insertions(+), 10 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext/largefiles/overrides.py Thu May 12 11:36:51 2016 +0200 +++ b/hgext/largefiles/overrides.py Thu May 12 11:48:39 2016 +0200 @@ -19,7 +19,7 @@ cmdutil, error, hg, - match as match_, + match as matchmod, pathutil, registrar, revset, @@ -113,13 +113,13 @@ if lfutil.islfilesrepo(repo): lfpats = ui.configlist(lfutil.longname, 'patterns', default=[]) if lfpats: - lfmatcher = match_.match(repo.root, '', list(lfpats)) + lfmatcher = matchmod.match(repo.root, '', list(lfpats)) lfnames = [] m = matcher wctx = repo[None] - for f in repo.walk(match_.badmatch(m, lambda x, y: None)): + for f in repo.walk(matchmod.badmatch(m, lambda x, y: None)): exact = m.exact(f) lfile = lfutil.standin(f) in wctx nfile = f in wctx @@ -321,7 +321,7 @@ if pat.startswith('set:'): return pat - kindpat = match_._patsplit(pat, None) + kindpat = matchmod._patsplit(pat, None) if kindpat[0] is not None: return kindpat[0] + ':' + tostandin(kindpat[1]) @@ -640,7 +640,7 @@ # The patterns were previously mangled to add the standin # directory; we need to remove that now for pat in pats: - if match_.patkind(pat) is None and lfutil.shortname in pat: + if matchmod.patkind(pat) is None and lfutil.shortname in pat: newpats.append(pat.replace(lfutil.shortname, '')) else: newpats.append(pat) @@ -658,7 +658,7 @@ oldmatch = installmatchfn(overridematch) listpats = [] for pat in pats: - if match_.patkind(pat) is not None: + if matchmod.patkind(pat) is not None: listpats.append(pat) else: listpats.append(makestandin(pat)) @@ -991,7 +991,7 @@ if subrepos: for subpath in sorted(ctx.substate): sub = ctx.workingsub(subpath) - submatch = match_.subdirmatcher(subpath, matchfn) + submatch = matchmod.subdirmatcher(subpath, matchfn) sub._repo.lfstatus = True sub.archive(archiver, prefix, submatch) @@ -1039,7 +1039,7 @@ for subpath in sorted(ctx.substate): sub = ctx.workingsub(subpath) - submatch = match_.subdirmatcher(subpath, match) + submatch = matchmod.subdirmatcher(subpath, match) sub._repo.lfstatus = True sub.archive(archiver, prefix + repo._path + '/', submatch) @@ -1204,7 +1204,7 @@ return orig(repo, matcher, prefix, opts, dry_run, similarity) # Get the list of missing largefiles so we can remove them lfdirstate = lfutil.openlfdirstate(repo.ui, repo) - unsure, s = lfdirstate.status(match_.always(repo.root, repo.getcwd()), [], + unsure, s = lfdirstate.status(matchmod.always(repo.root, repo.getcwd()), [], False, False, False) # Call into the normal remove code, but the removing of the standin, we want @@ -1389,7 +1389,7 @@ # (*1) deprecated, but used internally (e.g: "rebase --collapse") lfdirstate = lfutil.openlfdirstate(repo.ui, repo) - unsure, s = lfdirstate.status(match_.always(repo.root, + unsure, s = lfdirstate.status(matchmod.always(repo.root, repo.getcwd()), [], False, False, False) pctx = repo['.']