aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/configure.local.example
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2020-07-20 16:57:29 +0000
committerIngo Schwarze <schwarze@openbsd.org>2020-07-20 16:57:29 +0000
commiteb396f5b0bb17fecfc3db0045d2979fa42d4478d (patch)
tree3b8fb3cbf1050568658bfa9406b2b9eb514f1c0d /configure.local.example
parentd9eddf28f1aa31476f2335c1e6fc7002b64ea830 (diff)
downloadmandoc-eb396f5b0bb17fecfc3db0045d2979fa42d4478d.tar.gz
mandoc-eb396f5b0bb17fecfc3db0045d2979fa42d4478d.tar.zst
mandoc-eb396f5b0bb17fecfc3db0045d2979fa42d4478d.zip
Switch the default pager from "more -s" to "less".
POSIX explicitly allows using a different default pager if that is documented. Nowadays, the pager provided in most operating systems is less(1). Our man(1) implementation uses less(1) features that traditional more(1) did not provide, in particular tagging. Besides, as noted by deraadt@, the user interface of less(1) is slightly more refined and preferable over the user inferface of more(1). This switch was originally suggested by Ian Ropers. In ./configure, test whether less(1) is available. If not, fall back to more(1). In ./configure.local, support overriding the automatic test by setting BINM_PAGER. As explained by jmc@ and deraadt@, the -s flag was added a very long time ago when an antique version of groff(1) had an annoying bug in terminal output that would randomly display blank lines in the middle of pages. Clearly, -s has no longer been needed for many years, so drop it from the default pager invocation. OK deraadt@ jmc@ martijn@ job@ on the OpenBSD version of this patch.
Diffstat (limited to 'configure.local.example')
-rw-r--r--configure.local.example10
1 files changed, 9 insertions, 1 deletions
diff --git a/configure.local.example b/configure.local.example
index 63f16865..b717e477 100644
--- a/configure.local.example
+++ b/configure.local.example
@@ -1,4 +1,4 @@
-# $Id: configure.local.example,v 1.38 2020/06/22 20:00:38 schwarze Exp $
+# $Id: configure.local.example,v 1.39 2020/07/20 16:57:30 schwarze Exp $
#
# Copyright (c) 2014-2019 Ingo Schwarze <schwarze@openbsd.org>
#
@@ -151,6 +151,14 @@ BINM_WHATIS=mwhatis # default is "whatis"
BINM_MAKEWHATIS=mandocdb # default is "makewhatis"
BINM_SOELIM=msoelim # default is "soelim"
+# If less(1) is available, it is used as the default manual pager.
+# Otherwise, more(1) is used: its existence is required by POSIX.
+# It is possible to force using a different default pager, either
+# by giving the name of a program found in the PATH, or by giving
+# an absolute path.
+
+BINM_PAGER=pg # default is "less" or "more"
+
# Some distributions do not want hardlinks
# between installed binary programs.
# Set the following variable to use symbolic links instead.