##// END OF EJS Templates
subrepo: adjust subrepo prefix before calling subrepo.removefiles() (API)...
Martin von Zweigbergk -
r41775:2c549abc default
parent child Browse files
Show More
@@ -2208,11 +2208,12 b' def remove(ui, repo, m, prefix, after, f'
2208 unit=_('subrepos'))
2208 unit=_('subrepos'))
2209 for subpath in subs:
2209 for subpath in subs:
2210 submatch = matchmod.subdirmatcher(subpath, m)
2210 submatch = matchmod.subdirmatcher(subpath, m)
2211 subprefix = repo.wvfs.reljoin(prefix, subpath)
2211 if subrepos or m.exact(subpath) or any(submatch.files()):
2212 if subrepos or m.exact(subpath) or any(submatch.files()):
2212 progress.increment()
2213 progress.increment()
2213 sub = wctx.sub(subpath)
2214 sub = wctx.sub(subpath)
2214 try:
2215 try:
2215 if sub.removefiles(submatch, prefix, after, force, subrepos,
2216 if sub.removefiles(submatch, subprefix, after, force, subrepos,
2216 dryrun, warnings):
2217 dryrun, warnings):
2217 ret = 1
2218 ret = 1
2218 except error.LookupError:
2219 except error.LookupError:
@@ -847,8 +847,7 b' class hgsubrepo(abstractsubrepo):'
847 @annotatesubrepoerror
847 @annotatesubrepoerror
848 def removefiles(self, matcher, prefix, after, force, subrepos,
848 def removefiles(self, matcher, prefix, after, force, subrepos,
849 dryrun, warnings):
849 dryrun, warnings):
850 return cmdutil.remove(self.ui, self._repo, matcher,
850 return cmdutil.remove(self.ui, self._repo, matcher, prefix,
851 self.wvfs.reljoin(prefix, self._path),
852 after, force, subrepos, dryrun)
851 after, force, subrepos, dryrun)
853
852
854 @annotatesubrepoerror
853 @annotatesubrepoerror
General Comments 0
You need to be logged in to leave comments. Login now