config: activate pager if not starting an editor
authorAugie Fackler <augie@google.com>
Mon, 06 Feb 2017 23:01:42 -0500
changeset 31034 270ab9d2ffbb
parent 31033 861b070d92da
child 31035 8c176811b735
config: activate pager if not starting an editor This demonstrates the power of the non-attend-based pager API.
mercurial/commands.py
--- a/mercurial/commands.py	Mon Feb 06 23:57:21 2017 -0500
+++ b/mercurial/commands.py	Mon Feb 06 23:01:42 2017 -0500
@@ -1792,7 +1792,7 @@
         ui.system("%s \"%s\"" % (editor, f),
                   onerr=error.Abort, errprefix=_("edit failed"))
         return
-
+    ui.pager('config')
     fm = ui.formatter('config', opts)
     for f in scmutil.rcpath():
         ui.debug('read config from: %s\n' % f)