Mercurial > evolve
changeset 4622:86f396d2b352
revset: add `unstable` alias for `troubled`
Per https://www.mercurial-scm.org/wiki/CEDVocabulary. The old name is still
available (but undocumented) for compatibility. `Orphan` was renamed from
`unstable` in core in 4.4, so this seems safe to do now.
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Sat, 27 Apr 2019 22:24:30 -0400 |
parents | 8784dfc6537c |
children | 0adb59b55add |
files | hgext3rd/evolve/__init__.py hgext3rd/evolve/evolvecmd.py |
diffstat | 2 files changed, 10 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext3rd/evolve/__init__.py Sat Apr 27 21:54:52 2019 -0400 +++ b/hgext3rd/evolve/__init__.py Sat Apr 27 22:24:30 2019 -0400 @@ -500,13 +500,13 @@ "diff --hidden --rev 'limit(precursors(.),1)' --rev .", 'evolve') -### Troubled revset symbol +### Unstable revset symbol -@eh.revsetpredicate('troubled()') -def revsettroubled(repo, subset, x): - """Changesets with troubles. +@eh.revsetpredicate('unstable()') +def revsetunstable(repo, subset, x): + """Changesets with instabilities. """ - revset.getargs(x, 0, 0, 'troubled takes no arguments') + revset.getargs(x, 0, 0, 'unstable takes no arguments') troubled = set() troubled.update(getrevs(repo, 'orphan')) troubled.update(getrevs(repo, 'phasedivergent')) @@ -515,6 +515,10 @@ troubled.sort() # set is non-ordered, enforce order return subset & troubled +@eh.revsetpredicate('troubled()') # legacy name +def revsettroubled(repo, subset, x): + return revsetunstable(repo, subset, x) + ### Obsolescence graph # XXX SOME MAJOR CLEAN UP TO DO HERE XXX
--- a/hgext3rd/evolve/evolvecmd.py Sat Apr 27 21:54:52 2019 -0400 +++ b/hgext3rd/evolve/evolvecmd.py Sat Apr 27 22:24:30 2019 -0400 @@ -1197,7 +1197,7 @@ "orphan": repo.revs("orphan()"), "contentdivergent": repo.revs("contentdivergent()"), "phasedivergent": repo.revs("phasedivergent()"), - "all": repo.revs("troubled()"), + "all": repo.revs("unstable()"), } hintmap = {