##// END OF EJS Templates
revset: use field names instead of field numbers on scmutil.status...
Augie Fackler -
r44049:d212d657 default
parent child Browse files
Show More
@@ -673,6 +673,7 b' def checkstatus(repo, subset, pat, field'
673 1: added
673 1: added
674 2: removed
674 2: removed
675 """
675 """
676 label = {0: 'modified', 1: 'added', 2: 'removed'}[field]
676 hasset = matchmod.patkind(pat) == b'set'
677 hasset = matchmod.patkind(pat) == b'set'
677
678
678 mcache = [None]
679 mcache = [None]
@@ -691,7 +692,7 b' def checkstatus(repo, subset, pat, field'
691 else:
692 else:
692 if not any(m(f) for f in c.files()):
693 if not any(m(f) for f in c.files()):
693 return False
694 return False
694 files = repo.status(c.p1().node(), c.node())[field]
695 files = getattr(repo.status(c.p1().node(), c.node()), label)
695 if fname is not None:
696 if fname is not None:
696 if fname in files:
697 if fname in files:
697 return True
698 return True
General Comments 0
You need to be logged in to leave comments. Login now