##// END OF EJS Templates
dirstate: use keyword arguments to clarify status()'s callers...
Martin von Zweigbergk -
r34345:ac0cd81e default
parent child Browse files
Show More
@@ -169,7 +169,8 b' def openlfdirstate(ui, repo, create=True'
169 169 def lfdirstatestatus(lfdirstate, repo):
170 170 pctx = repo['.']
171 171 match = matchmod.always(repo.root, repo.getcwd())
172 unsure, s = lfdirstate.status(match, [], False, False, False)
172 unsure, s = lfdirstate.status(match, subrepos=[], ignored=False,
173 clean=False, unknown=False)
173 174 modified, clean = s.modified, s.clean
174 175 for lfile in unsure:
175 176 try:
@@ -551,8 +552,8 b' def updatestandinsbymatch(repo, match):'
551 552 # large.
552 553 lfdirstate = openlfdirstate(ui, repo)
553 554 dirtymatch = matchmod.always(repo.root, repo.getcwd())
554 unsure, s = lfdirstate.status(dirtymatch, [], False, False,
555 False)
555 unsure, s = lfdirstate.status(dirtymatch, subrepos=[], ignored=False,
556 clean=False, unknown=False)
556 557 modifiedfiles = unsure + s.modified + s.added + s.removed
557 558 lfiles = listlfiles(repo)
558 559 # this only loops through largefiles that exist (not
@@ -1218,8 +1218,9 b' def scmutiladdremove(orig, repo, matcher'
1218 1218 return orig(repo, matcher, prefix, opts, dry_run, similarity)
1219 1219 # Get the list of missing largefiles so we can remove them
1220 1220 lfdirstate = lfutil.openlfdirstate(repo.ui, repo)
1221 unsure, s = lfdirstate.status(matchmod.always(repo.root, repo.getcwd()), [],
1222 False, False, False)
1221 unsure, s = lfdirstate.status(matchmod.always(repo.root, repo.getcwd()),
1222 subrepos=[], ignored=False, clean=False,
1223 unknown=False)
1223 1224
1224 1225 # Call into the normal remove code, but the removing of the standin, we want
1225 1226 # to have handled by original addremove. Monkey patching here makes sure
@@ -1403,7 +1404,8 b' def mergeupdate(orig, repo, node, branch'
1403 1404 lfdirstate = lfutil.openlfdirstate(repo.ui, repo)
1404 1405 unsure, s = lfdirstate.status(matchmod.always(repo.root,
1405 1406 repo.getcwd()),
1406 [], False, True, False)
1407 subrepos=[], ignored=False,
1408 clean=True, unknown=False)
1407 1409 oldclean = set(s.clean)
1408 1410 pctx = repo['.']
1409 1411 dctx = repo[node]
@@ -162,8 +162,10 b' def reposetup(ui, repo):'
162 162 if sfindirstate(f)]
163 163 # Don't waste time getting the ignored and unknown
164 164 # files from lfdirstate
165 unsure, s = lfdirstate.status(match, [], False, listclean,
166 False)
165 unsure, s = lfdirstate.status(match, subrepos=[],
166 ignored=False,
167 clean=listclean,
168 unknown=False)
167 169 (modified, added, removed, deleted, clean) = (
168 170 s.modified, s.added, s.removed, s.deleted, s.clean)
169 171 if parentworking:
@@ -1756,12 +1756,11 b' class workingctx(committablectx):'
1756 1756
1757 1757 def _dirstatestatus(self, match, ignored=False, clean=False, unknown=False):
1758 1758 '''Gets the status from the dirstate -- internal use only.'''
1759 listignored, listclean, listunknown = ignored, clean, unknown
1760 1759 subrepos = []
1761 1760 if '.hgsub' in self:
1762 1761 subrepos = sorted(self.substate)
1763 cmp, s = self._repo.dirstate.status(match, subrepos, listignored,
1764 listclean, listunknown)
1762 cmp, s = self._repo.dirstate.status(match, subrepos, ignored=ignored,
1763 clean=clean, unknown=unknown)
1765 1764
1766 1765 # check for any possibly clean files
1767 1766 fixup = []
@@ -1770,7 +1769,7 b' class workingctx(committablectx):'
1770 1769 s.modified.extend(modified2)
1771 1770 s.deleted.extend(deleted2)
1772 1771
1773 if fixup and listclean:
1772 if fixup and clean:
1774 1773 s.clean.extend(fixup)
1775 1774
1776 1775 self._poststatusfixup(s, fixup)
General Comments 0
You need to be logged in to leave comments. Login now