hgweb: add some in-code documentation for 'web.view'
authorPierre-Yves David <pierre-yves.david@logilab.fr>
Thu, 07 Feb 2013 00:32:26 +0000
changeset 25565 be4dc0007b8d
parent 25564 847fce27effc
child 25566 15412bba5a68
hgweb: add some in-code documentation for 'web.view' This documentation was mostly intended for the user helps. However given the lack of request for such feature, we should keep it un-documented. We stick the help text in the code as it could still be useful to fellow contributors.
mercurial/hgweb/hgweb_mod.py
--- a/mercurial/hgweb/hgweb_mod.py	Thu Jun 11 17:19:48 2015 -0700
+++ b/mercurial/hgweb/hgweb_mod.py	Thu Feb 07 00:32:26 2013 +0000
@@ -100,6 +100,16 @@
                                        untrusted=untrusted)
 
     def _getview(self, repo):
+        """The 'web.view' config controls changeset filter to hgweb. Possible
+        values are ``served``, ``visible`` and ``all``. Default is ``served``.
+        The ``served`` filter only shows changesets that can be pulled from the
+        hgweb instance.  The``visible`` filter includes secret changesets but
+        still excludes "hidden" one.
+
+        See the repoview module for details.
+
+        The option has been around undocumented since Mercurial 2.5, but no
+        user ever asked about it. So we better keep it undocumented for now."""
         viewconfig = repo.ui.config('web', 'view', 'served',
                                     untrusted=True)
         if viewconfig == 'all':