diff options
author | 2018-10-02 14:56:36 +0000 | |
---|---|---|
committer | 2018-10-02 14:56:36 +0000 | |
commit | 3327fa001cdea3a379b54bd358dba2db2bfce9cd (patch) | |
tree | 772c92ca4404ff7139b09bdd7dd121acc03adc20 /usr.bin/mandoc/manpath.c | |
parent | mention INFO@openssh.com for sending SIGINFO (diff) | |
download | wireguard-openbsd-3327fa001cdea3a379b54bd358dba2db2bfce9cd.tar.xz wireguard-openbsd-3327fa001cdea3a379b54bd358dba2db2bfce9cd.zip |
Add an option -T html -O toc to add a brief table of contents near
the top of HTML pages containing at least two non-standard sections.
Suggested by Adam Kalisz and discussed with kristaps@ during EuroBSDCon 2018.
Diffstat (limited to 'usr.bin/mandoc/manpath.c')
-rw-r--r-- | usr.bin/mandoc/manpath.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/usr.bin/mandoc/manpath.c b/usr.bin/mandoc/manpath.c index 2c6e39b49f4..56370e73bef 100644 --- a/usr.bin/mandoc/manpath.c +++ b/usr.bin/mandoc/manpath.c @@ -1,6 +1,6 @@ -/* $OpenBSD: manpath.c,v 1.22 2017/07/01 09:47:23 schwarze Exp $ */ +/* $OpenBSD: manpath.c,v 1.23 2018/10/02 14:56:36 schwarze Exp $ */ /* - * Copyright (c) 2011, 2014, 2015, 2017 Ingo Schwarze <schwarze@openbsd.org> + * Copyright (c) 2011,2014,2015,2017,2018 Ingo Schwarze <schwarze@openbsd.org> * Copyright (c) 2011 Kristaps Dzonsons <kristaps@bsd.lv> * * Permission to use, copy, modify, and distribute this software for any @@ -233,7 +233,7 @@ manconf_output(struct manoutput *conf, const char *cp, int fromfile) { const char *const toks[] = { "includes", "man", "paper", "style", - "indent", "width", "fragment", "mdoc", "noval" + "indent", "width", "fragment", "mdoc", "noval", "toc" }; const char *errstr; @@ -320,6 +320,9 @@ manconf_output(struct manoutput *conf, const char *cp, int fromfile) case 8: conf->noval = 1; return 0; + case 9: + conf->toc = 1; + return 0; default: if (fromfile) warnx("-O %s: Bad argument", cp); |