Mercurial > hg
changeset 43641:705738def50c
split: use field names instead of field numbers on scmutil.status
As part of my pytype adventures I want to make scmutil.status no longer a
subclass of tuple. This is part of that process.
Differential Revision: https://phab.mercurial-scm.org/D7393
author | Augie Fackler <augie@google.com> |
---|---|
date | Thu, 14 Nov 2019 15:25:48 -0500 |
parents | 2d5b991c2192 |
children | 96edd0c38740 |
files | hgext/split.py |
diffstat | 1 files changed, 3 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext/split.py Thu Nov 14 15:25:40 2019 -0500 +++ b/hgext/split.py Thu Nov 14 15:25:48 2019 -0500 @@ -152,7 +152,9 @@ scmutil.movedirstate(repo, ctx.p1()) # Any modified, added, removed, deleted result means split is incomplete - incomplete = lambda repo: any(repo.status()[:4]) + def incomplete(repo): + st = repo.status() + return any((st.modified, st.added, st.removed, st.deleted)) # Main split loop while incomplete(repo):