repoview: add a new filtername for accessing hidden commits
This patch adds a new filter 'visible-hidden' for repository and will be used to
return a repo object with user passed revisions unhidden. Unlike the
directaccess extension in fb-hgext and previous series adding the functionality,
this time we introduce only one new filter as whether to warn user or not is
handled by scmutil.unhidehashlikerevs().
Differential Revision: https://phab.mercurial-scm.org/D1734
--- a/mercurial/branchmap.py Fri Dec 15 04:25:32 2017 +0530
+++ b/mercurial/branchmap.py Mon Dec 18 17:50:02 2017 +0530
@@ -84,6 +84,7 @@
# This create and ordering used for branchmap purpose.
# the ordering may be partial
subsettable = {None: 'visible',
+ 'visible-hidden': 'visible',
'visible': 'served',
'served': 'immutable',
'immutable': 'base'}
--- a/mercurial/repoview.py Fri Dec 15 04:25:32 2017 +0530
+++ b/mercurial/repoview.py Mon Dec 18 17:50:02 2017 +0530
@@ -143,6 +143,7 @@
# Otherwise your filter will have to recompute all its branches cache
# from scratch (very slow).
filtertable = {'visible': computehidden,
+ 'visible-hidden': computehidden,
'served': computeunserved,
'immutable': computemutable,
'base': computeimpactable}