Mercurial > public > mercurial-scm > hg
diff mercurial/revset.py @ 17829:c73f7a28953c
revset: add a bumped revset
Select bumped changesets.
author | Pierre-Yves David <pierre-yves.david@logilab.fr> |
---|---|
date | Fri, 19 Oct 2012 00:39:06 +0200 |
parents | 3cc06457f15e |
children | d8905e2c1301 |
line wrap: on
line diff
--- a/mercurial/revset.py Fri Oct 19 00:36:18 2012 +0200 +++ b/mercurial/revset.py Fri Oct 19 00:39:06 2012 +0200 @@ -422,6 +422,17 @@ s = set(s) return [r for r in subset if r in s or repo[r].branch() in b] +def bumped(repo, subset, x): + """``bumped()`` + Mutable changesets marked as successors of public changesets. + + Only non-public and non-obsolete changesets can be `bumped`. + """ + # i18n: "bumped" is a keyword + getargs(x, 0, 0, _("bumped takes no arguments")) + bumped = obsmod.getrevs(repo, 'bumped') + return [r for r in subset if r in bumped] + def checkstatus(repo, subset, pat, field): m = None s = [] @@ -1492,6 +1503,7 @@ "bookmark": bookmark, "branch": branch, "branchpoint": branchpoint, + "bumped": bumped, "children": children, "closed": closed, "contains": contains,