OpenBSD CVS

CVS log for src/usr.bin/mandoc/mandoc.1


[BACK] Up to [local] / src / usr.bin / mandoc

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.193 / (download) - annotate - [select for diffs], Mon Nov 13 19:13:00 2023 UTC (6 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, HEAD
Changes since 1.192: +4 -8 lines
Diff to previous 1.192 (colored)

Reduce the man(7) default global indentation from 7n, which was an oddity
in groff-1.01 to groff-1.22.4, to 5n for compatibility with Version 7 AT&T
UNIX, 4.3BSD-Reno, groff-1.23.0, and all versions of mdoc(7).
OK jmc@ millert@

Revision 1.192 / (download) - annotate - [select for diffs], Tue Oct 24 20:30:49 2023 UTC (6 months, 3 weeks ago) by schwarze
Branch: MAIN
Changes since 1.191: +19 -9 lines
Diff to previous 1.191 (colored)

Implement the man(7) .MR macro, a 2023 GNU extension.
The syntax and semantics is almost identical to mdoc(7) .Xr.

This will be needed for reading the groff manual pages once our port
will be updated to 1.23, and the Linux Manual Pages Project is also
determined to start using it sooner or later.  I did not advocate for
this new macro, but since we want to remain able to read all manual
pages found in the wild, there is little choice but to support it.
At least it is easy to do, they basically copied .Xr.

Revision 1.191 / (download) - annotate - [select for diffs], Wed Oct 18 14:47:22 2023 UTC (7 months ago) by schwarze
Branch: MAIN
Changes since 1.190: +44 -15 lines
Diff to previous 1.190 (colored)

Better document the purpose and features of the file mandoc.css
and the purpose and limitations of the embedded stylesheet.

Triggered by a conversation with Alejandro Colomar <alx at kernel dot org>.

Revision 1.190 / (download) - annotate - [select for diffs], Thu Dec 22 19:53:23 2022 UTC (16 months, 3 weeks ago) by kn
Branch: MAIN
CVS Tags: OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3
Changes since 1.189: +4 -6 lines
Diff to previous 1.189 (colored)

Denote multiple arguments with 'arg ...' not 'args'

A few programs used the plural in their synopsis which doesn't read as
clear as the obvious triple-dot notation.

mdoc(7) .Ar defaults to "file ..." if no arguments are given and consistent
use of 'arg ...' matches that behaviour.

Cleanup a few markups of the same argument so the text keeps reading
naturally;  omit unhelpful parts like 'if optional arguments are given,
they are passed along' for tools like time(1) and timeout(1) that obviously
execute commands with whatever arguments where given -- just like doas(1)
which doesn't mention arguments in its DESCRIPTION in the first place.

For expr(1) the difference between 'expressions' and 'expression ...' is
crucial, as arguments must be passed as individual words.

Feedback millert jmc schwarze deraadt
OK jmc

Revision 1.189 / (download) - annotate - [select for diffs], Tue Aug 2 11:55:51 2022 UTC (21 months, 2 weeks ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_7_2_BASE, OPENBSD_7_2
Changes since 1.188: +3 -5 lines
Diff to previous 1.188 (colored)

If the body of a man(7) .MT or .UR block is empty, do not emit a warning.
Leaving the body empty is legitimate in this case if the author only
wants to display a mail address or URI without providing a link text.
Output modules already handle this correctly: terminal output shows
just the URI without an accompanying text, HTML output uses the URI
for *both* the href= attribute and as the content of the <a> element.

The documentation was also wrong and claimed that an .MT or .UR block
with an empty body would produce no output.  As explained above,
this isn't true.

Bogus warning reported by
Alejandro Colomar <alx dot manpages at gmail dot com>.

Revision 1.188 / (download) - annotate - [select for diffs], Tue Jun 28 04:36:29 2022 UTC (22 months, 3 weeks ago) by jsg
Branch: MAIN
Changes since 1.187: +3 -3 lines
Diff to previous 1.187 (colored)

spelling

Revision 1.187 / (download) - annotate - [select for diffs], Wed Jun 22 17:34:57 2022 UTC (22 months, 3 weeks ago) by schwarze
Branch: MAIN
Changes since 1.186: +2 -3 lines
Diff to previous 1.186 (colored)

Delete the statement that the default stylesheet only used CSS1
because that has no longer been true for some time now.

I would certainly like to adhere to a coherent standard and state
which one that is.  Unfortunately, the W3C deliberately smashed
the CSS standard into pieces such that a coherent standard no
longer exists and such that statements about standard conformance
have become next to meaningless.  Consequently, i now remain
reluctantly silent regarding CSS standard(s) conformance.

Going back to CSS2.1, published in 2011, which was the last CSS
standard in the proper sense of the word, is not an option because
it has gaping holes in functionality and is no longer adequate for
use on today's WWW.

Revision 1.186 / (download) - annotate - [select for diffs], Tue Jun 7 09:51:03 2022 UTC (23 months, 1 week ago) by schwarze
Branch: MAIN
Changes since 1.185: +16 -5 lines
Diff to previous 1.185 (colored)

Split the excessively generic diagnostic message "invalid escape sequence"
into the more specific messages "invalid escape argument delimiter"
and "invalid escape sequence argument".

Revision 1.185 / (download) - annotate - [select for diffs], Sun Jun 5 13:42:49 2022 UTC (23 months, 2 weeks ago) by schwarze
Branch: MAIN
Changes since 1.184: +47 -17 lines
Diff to previous 1.184 (colored)

With the improved escape sequence parser, it becomes easy to also improve
diagnostics.  Distinguish "incomplete escape sequence", "invalid special
character", and "unknown special character" from the generic "invalid
escape sequence", also promoting them from WARNING to ERROR because
incomplete escape sequences are severe syntax violations and because
encountering an invalid or unknown special character makes it likely
that part of the document content intended by the authors gets lost.

Revision 1.184 / (download) - annotate - [select for diffs], Thu Apr 28 16:16:46 2022 UTC (2 years ago) by schwarze
Branch: MAIN
Changes since 1.183: +18 -2 lines
Diff to previous 1.183 (colored)

The syntax of the roff(7) .mc request is quite special
and the roff_onearg() parsing function is too generic,
so provide a dedicated parsing function instead.

This fixes an assertion failure when an \o escape sequence is
passed as the argument; the bug was found by tb@ using afl(1).
It also makes mandoc output more similar to groff in various cases.

Revision 1.183 / (download) - annotate - [select for diffs], Sun Apr 24 13:34:53 2022 UTC (2 years ago) by schwarze
Branch: MAIN
Changes since 1.182: +10 -3 lines
Diff to previous 1.182 (colored)

If a .shift request has a negative argument, do not use a negative array
index but use 0 instead of the argument, just like groff.
Warn about the invalid argument.
While here, fix the column number in another warning message.

Segfault reported by tb@, found with afl(1).

Revision 1.182 / (download) - annotate - [select for diffs], Fri Feb 18 10:24:32 2022 UTC (2 years, 2 months ago) by jsg
Branch: MAIN
CVS Tags: OPENBSD_7_1_BASE, OPENBSD_7_1
Changes since 1.181: +4 -4 lines
Diff to previous 1.181 (colored)

prefer https links in man pages
ok gnezdo@ miod@ jmc@

Revision 1.181 / (download) - annotate - [select for diffs], Tue Feb 8 18:23:11 2022 UTC (2 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.180: +3 -3 lines
Diff to previous 1.180 (colored)

In the first example, use "mandoc -a" directly rather "mandoc -l".

It feels more natural to me to use -a directly when asking mandoc(1)
to use a pager.  The reason that "mandoc -l" does exactly the same
as "mandoc -a" is that "mandoc" is essentially "man -lc", so the -a
implied by -l negates the -c and the -l has no effect because it is
already the default for mandoc(1).

The more usual command for doing the same is "man -l foo.1 bar.1 ..."
but that's off-topic for the mandoc(1) manual page.

Patch on tech@ from Anders Damsgaard <anders at adamsgaard dot dk>.

Revision 1.180 / (download) - annotate - [select for diffs], Sun Feb 6 00:29:03 2022 UTC (2 years, 3 months ago) by jsg
Branch: MAIN
Changes since 1.179: +3 -3 lines
Diff to previous 1.179 (colored)

remove please from manual pages
ok jmc@ sthen@ millert@

Revision 1.179 / (download) - annotate - [select for diffs], Sat Aug 14 13:51:46 2021 UTC (2 years, 9 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_7_0_BASE, OPENBSD_7_0
Changes since 1.178: +10 -2 lines
Diff to previous 1.178 (colored)

print a BAGARG message if -T markdown is requested on man(7) input;
suggested by Michael Stapelberg at debian dot org

Revision 1.178 / (download) - annotate - [select for diffs], Sun Jul 4 15:38:08 2021 UTC (2 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.177: +22 -2 lines
Diff to previous 1.177 (colored)

The mandoc(1) manual already mentions that -T man output mode
neither supports tbl(7) nor eqn(7) input.
If an input file contains such code anyway, tell the user
rather than failing an assert(3)ion.

Fixing a crash reported by Bjarni Ingi Gislason <bjarniig at rhi dot hi dot is>
in https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=901636 which the
Debian maintainer of mandoc, Michael at Stapelberg dot ch, forwarded to me.

Revision 1.177 / (download) - annotate - [select for diffs], Mon Jun 28 19:49:57 2021 UTC (2 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.176: +4 -4 lines
Diff to previous 1.176 (colored)

In terminal output of man(7) documents, stop printing two extra blank
lines before the NAME section and before the page footer.  While these
blank lines had a long tradition, they didn't really serve any purpose
and merely wasted screen real estate.  Besides, this makes output from
man(7) more similar to output from mdoc(7).

This commit keeps mandoc compatible with groff-current,
where G. Branden Robinson committed the same change
on June 16 (groff commit 2278d6ed).

Revision 1.176 / (download) - annotate - [select for diffs], Sun Jun 27 17:57:13 2021 UTC (2 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.175: +5 -2 lines
Diff to previous 1.175 (colored)

add a style message about overlong text lines,
trying very hard to avoid false positives,
not at all trying to catch as many cases as possible;

feature originally suggested by tb@,
OK tb@ kn@ jmc@

Revision 1.175 / (download) - annotate - [select for diffs], Wed Jun 2 18:27:36 2021 UTC (2 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.174: +32 -11 lines
Diff to previous 1.174 (colored)

In -W style mode, check .Xr links along the full manpath because
that is more useful for validating manuals of non-base software.
Nothing changes in -W all mode: by default for -T lint, we still
assume we want to check base system conventions, including usually
not wanting to link to non-base manual pages.

The use case, a partial idea how to handle it, and a preliminary
patch was originally presented by kn@, then refined by me.
Final patch tested and OK'ed by kn@.

Revision 1.174 / (download) - annotate - [select for diffs], Sun Apr 4 06:18:58 2021 UTC (3 years, 1 month ago) by jmc
Branch: MAIN
CVS Tags: OPENBSD_6_9_BASE, OPENBSD_6_9
Changes since 1.173: +3 -3 lines
Diff to previous 1.173 (colored)

fix spacing issue in macro;

Revision 1.173 / (download) - annotate - [select for diffs], Tue Sep 1 18:24:09 2020 UTC (3 years, 8 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_6_8_BASE, OPENBSD_6_8
Changes since 1.172: +5 -1 lines
Diff to previous 1.172 (colored)

Ignore unreasonably large spacing modifiers in tbl layouts.

Jan Schreiber <jes at posteo dot de> ran afl on mandoc and it turned
out mandoc tried to use spacing modifiers so large that they would
trigger assertion failures in term_ascii.c, function locale_advance().

Revision 1.172 / (download) - annotate - [select for diffs], Thu Aug 27 15:54:38 2020 UTC (3 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.171: +3 -6 lines
Diff to previous 1.171 (colored)

Remove a lie reported by Jamie Landeg-Jones <jamie at catflap dot org>:
The times when -T man may have expanded .so requests are long gone,
nor would such a feature be useful.  Use soelim(1) if you need that.

Revision 1.171 / (download) - annotate - [select for diffs], Thu Aug 27 14:28:08 2020 UTC (3 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.170: +9 -2 lines
Diff to previous 1.170 (colored)

Make it more explicit that the statement "-O tag does not work with less(1)"
only applies to -T html output mode, and why.  Of course, -O tag works
just fine with less(1) in the -T ascii and -T utf8 output modes.
Potential for confusion pointed out by Ian Ropers.

Revision 1.170 / (download) - annotate - [select for diffs], Mon Jul 20 14:52:12 2020 UTC (3 years, 9 months ago) by schwarze
Branch: MAIN
Changes since 1.169: +4 -5 lines
Diff to previous 1.169 (colored)

as jmc@ points out, i missed a few instances of .Xr more 1

Revision 1.169 / (download) - annotate - [select for diffs], Mon Jul 20 14:25:22 2020 UTC (3 years, 9 months ago) by schwarze
Branch: MAIN
Changes since 1.168: +4 -4 lines
Diff to previous 1.168 (colored)

Switch the default pager from "more -s" to "less".

POSIX explicitly allows using a different default pager if that
is documented.  The pager provided in the OpenBSD base system is
less(1).  It can merely be called as more(1) for compatibility.
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.

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@

Revision 1.168 / (download) - annotate - [select for diffs], Mon Jun 15 18:05:25 2020 UTC (3 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.167: +19 -2 lines
Diff to previous 1.167 (colored)

document -T html -O tag as implemented in main.c rev. 1.253

Revision 1.167 / (download) - annotate - [select for diffs], Fri Apr 24 11:58:02 2020 UTC (4 years ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_6_7_BASE, OPENBSD_6_7
Changes since 1.166: +17 -3 lines
Diff to previous 1.166 (colored)

provide a STYLE message when mandoc knows the file name and the extension
disagrees with the section number given in the .Dt or .TH macro;
feature suggested and patch tested by jmc@

Revision 1.166 / (download) - annotate - [select for diffs], Sat Feb 15 15:28:01 2020 UTC (4 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.165: +8 -3 lines
Diff to previous 1.165 (colored)

mention that -T man does not support eqn(7) and tbl(7);
triggered by a question from Stephen Gregoratto <dev at sgregoratto dot me>

Revision 1.165 / (download) - annotate - [select for diffs], Sun Jan 19 16:16:32 2020 UTC (4 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.164: +3 -3 lines
Diff to previous 1.164 (colored)

Align to the new, sane behaviour of the groff_mdoc(7) .Dd macro:
without an argument, use the empty string, and always concatenate
all arguments, no matter their number.
This allows reducing the number of arguments of mandoc_normdate()
and some other simplifications, at the same time polishing some
error messages by adding the name of the macro in question.

Revision 1.164 / (download) - annotate - [select for diffs], Wed Jul 10 19:38:56 2019 UTC (4 years, 10 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_6_6_BASE, OPENBSD_6_6
Changes since 1.163: +49 -6 lines
Diff to previous 1.163 (colored)

Some time ago, i simplified mandoc_msg() such that it can be used
everywhere and not only in the parsers.
For more uniform messages, use it at more places instead of err(3),
in particular in the main program.
While here, integrate a few trivial functions called at exactly one
place into the main option parser, and let a few more functions use
the normal convention of returning 0 for success and -1 for error.

Revision 1.163 / (download) - annotate - [select for diffs], Sun May 26 01:16:09 2019 UTC (4 years, 11 months ago) by naddy
Branch: MAIN
Changes since 1.162: +4 -3 lines
Diff to previous 1.162 (colored)

use proper crossreferences

Revision 1.162 / (download) - annotate - [select for diffs], Tue Apr 30 11:48:03 2019 UTC (5 years ago) by schwarze
Branch: MAIN
Changes since 1.161: +6 -3 lines
Diff to previous 1.161 (colored)

improve the description of the message "blank line in fill mode";
triggered by a misunderstanding by sashan@

Revision 1.161 / (download) - annotate - [select for diffs], Sat Feb 23 18:52:45 2019 UTC (5 years, 2 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_6_5_BASE, OPENBSD_6_5
Changes since 1.160: +13 -2 lines
Diff to previous 1.160 (colored)

Explain the ASCII rendering of single quotes because that repeatedly
caused confusion in the past.  People plainly do not expect that
there are limits to the compatibility between Unicode and ASCII,
but there are.

The information belongs here and not into mandoc_char(7) because
it explains how the specific output device (-T ascii) works and
because it has nothing to do with the question of how characters
are represented on the input side.

Revision 1.160 / (download) - annotate - [select for diffs], Tue Jan 1 08:18:06 2019 UTC (5 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.159: +12 -4 lines
Diff to previous 1.159 (colored)

Support taking the -O tag value from apropos(1) key=value search terms;
feature improvement suggested by kn@.
While here, also make "-O value" work from standard input.
OK kn@

Revision 1.159 / (download) - annotate - [select for diffs], Thu Dec 27 23:53:47 2018 UTC (5 years, 4 months ago) by tedu
Branch: MAIN
Changes since 1.158: +9 -2 lines
Diff to previous 1.158 (colored)

add some notes about using col and ul to process the ascii markup
since these may not be commonly known utilities.
with schwarze

Revision 1.158 / (download) - annotate - [select for diffs], Mon Dec 24 20:42:03 2018 UTC (5 years, 4 months ago) by tedu
Branch: MAIN
Changes since 1.157: +9 -9 lines
Diff to previous 1.157 (colored)

mandoc.css lives in /usr/share/misc now; use full paths to indicate this.
ok schwarze

Revision 1.157 / (download) - annotate - [select for diffs], Thu Dec 20 18:23:18 2018 UTC (5 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.156: +21 -5 lines
Diff to previous 1.156 (colored)

Explain what the fields in mandoc messages mean,
rather than merely specifying the message syntax.
Gap in documentation found while looking at a bug
report from Raf Czlonka <rczlonka at gmail dot com>.

Revision 1.156 / (download) - annotate - [select for diffs], Sat Dec 15 19:30:19 2018 UTC (5 years, 5 months ago) by schwarze
Branch: MAIN
Changes since 1.155: +17 -3 lines
Diff to previous 1.155 (colored)

Several improvements to escape sequence handling.

* Add the missing special character \_ (underscore).
* Partial implementations of \a (leader character)
and \E (uninterpreted escape character).
* Parse and ignore \r (reverse line feed).
* Add a WARNING message about undefined escape sequences.
* Add an UNSUPP message about unsupported escape sequences.
* Mark \! and \? (transparent throughput)
and \O (suppress output) as unsupported.
* Treat the various variants of zero-width spaces as one-byte escape
sequences rather than as special characters, to avoid defining bogus
forms with square brackets.
* For special characters with one-byte names, do not define bogus
forms with square brackets, except for \[-], which is valid.
* In the form with square brackets, undefined special characters do not
fall back to printing the name verbatim, not even for one-byte names.
* Starting a special character name with a blank is an error.
* Undefined escape sequences never abort formatting of the input
string, not even in HTML output mode.
* Document the newly handled escapes, and a few that were missing.
* Regression tests for most of the above.

Revision 1.155 / (download) - annotate - [select for diffs], Thu Nov 22 11:30:15 2018 UTC (5 years, 5 months ago) by schwarze
Branch: MAIN
Changes since 1.154: +13 -1 lines
Diff to previous 1.154 (colored)

In -T locale (the default), -T ascii, and -T utf8 mode, provide a new
output option -O tag[=term] to move right to the definition of "term" when
opening the manual page in a pager, effectively porting the -T html
fragment name feature - https://man.openbsd.org/ksh#ulimit - to the
terminal.  Try:

$ man -O tag uvm_sysctl
$ man -O tag=ulimit ksh
$ man -O tag 3 compress

Feature development triggered by a question from kn@.  Klemens also
tested, provided feedback that resulted in improvements, and provided
an OK.

Revision 1.154 / (download) - annotate - [select for diffs], Tue Oct 2 14:56:36 2018 UTC (5 years, 7 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_6_4_BASE, OPENBSD_6_4
Changes since 1.153: +5 -2 lines
Diff to previous 1.153 (colored)

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.

Revision 1.153 / (download) - annotate - [select for diffs], Tue Oct 2 12:32:55 2018 UTC (5 years, 7 months ago) by schwarze
Branch: MAIN
Changes since 1.152: +7 -3 lines
Diff to previous 1.152 (colored)

Support a second argument to -O man,
selecting the format according to local existence of the file.
Suggested by kristaps@ during EuroBSDCon 2018.
Written on the train Frankfurt-Karlsruhe returning from EuroBSDCon.

Revision 1.152 / (download) - annotate - [select for diffs], Sat Aug 25 16:43:52 2018 UTC (5 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.151: +15 -2 lines
Diff to previous 1.151 (colored)

Rudimentary implementation of the roff(7) .char (output glyph
definition) request, used for example by groff_hdtbl(7).

This simplistic implementation may interact incorrectly
with the .tr (input character translation) request.
But come on, you are not only using .char *and* .tr, but you do so
with respect to the same character in the same manual page?

Revision 1.151 / (download) - annotate - [select for diffs], Thu Aug 23 14:16:12 2018 UTC (5 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.150: +24 -2 lines
Diff to previous 1.150 (colored)

Implement the roff(7) .shift and .return requests,
for example used by groff_hdtbl(7) and groff_mom(7).

Also correctly interpolate arguments during nested macro execution
even after .shift and .return, implemented using a stack of argument
arrays.

Note that only read.c, but not roff.c can detect the end of a macro
execution, and the existence of .shift implies that arguments cannot
be interpolated up front, so unfortunately, this includes a partial
revert of roff.c rev. 1.209, moving argument interpolation back into
the function roff_res().

Revision 1.150 / (download) - annotate - [select for diffs], Sat Jul 28 18:32:30 2018 UTC (5 years, 9 months ago) by schwarze
Branch: MAIN
Changes since 1.149: +12 -2 lines
Diff to previous 1.149 (colored)

Issue a STYLE message when normalizing the date format in .Dd/.TH.
Leah Neukirchen pointed out that mdoclint(1) used to warn about a
leading zero before the day number, so we know that both NetBSD and
Void Linux want the message.  It does no harm on OpenBSD because
Mdocdate always does the right thing anyway.
jmc@ agrees that it makes sense in contexts not using Mdocdate.

Revision 1.149 / (download) - annotate - [select for diffs], Thu May 3 14:21:20 2018 UTC (6 years ago) by schwarze
Branch: MAIN
Changes since 1.148: +3 -3 lines
Diff to previous 1.148 (colored)

Minor correction: we render HTML character references hexadecimal,
not decimal; bentley@ changed that in html.c on July 14, 2017.

Revision 1.148 / (download) - annotate - [select for diffs], Sun Apr 29 14:27:28 2018 UTC (6 years ago) by schwarze
Branch: MAIN
Changes since 1.147: +87 -101 lines
Diff to previous 1.147 (colored)

Simpler description of output formats, shortening the manual page by 15 lines.
Avoid the double redirection from -Tutf8 via -Tlocale to -Tascii.
Add LC_CTYPE to the ENVIRONMENT section.
While here, also correct a few inaccuracies and tweak some wordings.
Triggered by a question from Laura Morales <lauretas at mail dot com>.

Revision 1.147 / (download) - annotate - [select for diffs], Fri Apr 13 19:55:13 2018 UTC (6 years, 1 month ago) by schwarze
Branch: MAIN
Changes since 1.146: +10 -6 lines
Diff to previous 1.146 (colored)

Use TIOCGWINSZ to reduce the default -Owidth during interactive use
on terminals narrower than 79 columns and the default -Oindent on
terminals narrower than 66 columns.
Requested by and feedback from pirofti@;
mpi@ and juanfra@ also like the general direction.

Revision 1.146 / (download) - annotate - [select for diffs], Fri Mar 16 15:05:33 2018 UTC (6 years, 2 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_6_3_BASE, OPENBSD_6_3
Changes since 1.145: +9 -3 lines
Diff to previous 1.145 (colored)

Style message about bad input encoding of em-dashes as -- instead of \(em.
Suggested by Thomas Klausner <wiz at NetBSD>; discussed with jmc@.

Revision 1.145 / (download) - annotate - [select for diffs], Tue Nov 28 20:26:03 2017 UTC (6 years, 5 months ago) by schwarze
Branch: MAIN
Changes since 1.144: +3 -3 lines
Diff to previous 1.144 (colored)

duplicate word, found by igor(1)

Revision 1.144 / (download) - annotate - [select for diffs], Fri Nov 10 22:48:05 2017 UTC (6 years, 6 months ago) by jca
Branch: MAIN
Changes since 1.143: +3 -3 lines
Diff to previous 1.143 (colored)

Be less assertive when warning about a possible typo.

ok schwarze@ "good compromise" jmc@

Revision 1.143 / (download) - annotate - [select for diffs], Thu Sep 7 14:22:58 2017 UTC (6 years, 8 months ago) by dcoppa
Branch: MAIN
CVS Tags: OPENBSD_6_2_BASE, OPENBSD_6_2
Changes since 1.142: +3 -3 lines
Diff to previous 1.142 (colored)


typo: convertion -> convention

OK schwarze@

Revision 1.142 / (download) - annotate - [select for diffs], Sat Aug 19 21:59:46 2017 UTC (6 years, 9 months ago) by schwarze
Branch: MAIN
Changes since 1.141: +16 -2 lines
Diff to previous 1.141 (colored)

document -O mdoc; triggered by a question from jmc@ and OK jmc@

Revision 1.141 / (download) - annotate - [select for diffs], Thu Jul 20 15:26:35 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.140: +5 -3 lines
Diff to previous 1.140 (colored)

For -Tlint, put parser messages on stdout instead of stderr.

Originally, naddy@ requested this in 2011 (or maybe even earlier).
It was discussed with joerg@, kristaps@, naddy@, and espie@ in 2011,
and everybody agreed in principle, but it was postponed because
kristaps@ wanted to do some cleanup of the message system first.
Meanwhile, message infrastructure was improved about a dozen times...

This makes long, tedious commands like "mandoc -Tlint *.1 2>&1 | less"
unnecessary and allows simple ones like "man -l -Tlint *.1".

Revision 1.140 / (download) - annotate - [select for diffs], Fri Jul 7 16:19:30 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.139: +8 -27 lines
Diff to previous 1.139 (colored)

Radically simplify the definitions what the message levels ERROR
and WARNING mean: minus 20 lines of mdoc source.  OK jmc@.

Revision 1.139 / (download) - annotate - [select for diffs], Thu Jul 6 22:58:44 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.138: +58 -58 lines
Diff to previous 1.138 (colored)

Now that we have the -Wstyle message level, downgrade six warnings
that are not syntax mistakes and that do not cause wrong formatting
or content to style suggestions.
Also upgrade two warnings that may cause information loss to errors.

Revision 1.138 / (download) - annotate - [select for diffs], Tue Jul 4 14:40:30 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.137: +7 -1 lines
Diff to previous 1.137 (colored)

Printing "BASE:" in messages about violations of base system conventions
is confusing, simply print "STYLE:", which is intuitive and does not
sound excessively alarming; suggested by jmc@, OK tedu@ jmc@.

Revision 1.137 / (download) - annotate - [select for diffs], Mon Jul 3 17:33:01 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.136: +10 -6 lines
Diff to previous 1.136 (colored)

report trailing delimiters after macros where they are usually a mistake;
the idea came up in a discussion with Thomas Klausner <wiz at NetBSD>

Revision 1.136 / (download) - annotate - [select for diffs], Mon Jul 3 13:40:00 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.135: +10 -2 lines
Diff to previous 1.135 (colored)

warn about time machines; suggested by Thomas Klausner <wiz @ NetBSD>

Revision 1.135 / (download) - annotate - [select for diffs], Sun Jul 2 15:31:48 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.134: +20 -2 lines
Diff to previous 1.134 (colored)

add warning "cross reference to self"; inspired by mdoclint

Revision 1.134 / (download) - annotate - [select for diffs], Sat Jul 1 09:47:23 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.133: +10 -2 lines
Diff to previous 1.133 (colored)

Basic reporting of .Xrs to manual pages that don't exist
in the base system, inspired by mdoclint(1).

We are able to do this because (1) the -mdoc parser, the -Tlint validator,
and the man(1) manual page lookup code are all in the same program
and (2) the mandoc.db(5) database format allows fast lookup.

Feedback from, previous versions tested by, and OK jmc@.

A few features will be added to this in the tree, step by step.

Revision 1.133 / (download) - annotate - [select for diffs], Thu Jun 29 15:21:46 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.132: +19 -2 lines
Diff to previous 1.132 (colored)

warn about some non-portable idioms in .Bl -column;
triggered by a question from Yuri Pankov (illumos)

Revision 1.132 / (download) - annotate - [select for diffs], Tue Jun 27 12:17:35 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.131: +4 -2 lines
Diff to previous 1.131 (colored)

warn about .Ns macros that have no effect because they are followed
by an isolated closing delimiter; inspired by mdoclint

Revision 1.131 / (download) - annotate - [select for diffs], Sun Jun 25 17:42:37 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.130: +7 -2 lines
Diff to previous 1.130 (colored)

Catch typos in .Sh names; suggested by jmc@.

I'm using a very simple, linear time / zero space fuzzy string
matching heuristic rather than a full Levenshtein metric, to keep
the code both simple and fast.

Revision 1.130 / (download) - annotate - [select for diffs], Sun Jun 25 07:23:53 2017 UTC (6 years, 10 months ago) by bentley
Branch: MAIN
Changes since 1.129: +7 -3 lines
Diff to previous 1.129 (colored)

Add support for the MT and ME mailto macros, used for example in wg(8).

feedback and ok schwarze@

Revision 1.129 / (download) - annotate - [select for diffs], Sat Jun 24 21:08:28 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.128: +2 -2 lines
Diff to previous 1.128 (colored)

delete useless .Ns macro that jmc@ found with mdoclint(1)

Revision 1.128 / (download) - annotate - [select for diffs], Sat Jun 24 19:05:36 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.127: +7 -1 lines
Diff to previous 1.127 (colored)

document message "unknown architecture"

Revision 1.127 / (download) - annotate - [select for diffs], Sat Jun 24 15:59:28 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.126: +8 -2 lines
Diff to previous 1.126 (colored)

in the base system, suggest leaving .Os blank; inspired by mdoclint

Revision 1.126 / (download) - annotate - [select for diffs], Sat Jun 24 14:38:27 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.125: +70 -29 lines
Diff to previous 1.125 (colored)

Split -Wstyle into -Wstyle and the even lower -Wbase, and add
-Wopenbsd and -Wnetbsd to check conventions for the base system of
a specific operating system.  Mark operating system specific messages
with "(OpenBSD)" at the end.

Please use just "-Tlint" to check base system manuals (defaulting
to -Wall, which is now -Wbase), but prefer "-Tlint -Wstyle" for the
manuals of portable software projects you maintain that are not
part of OpenBSD base, to avoid bogus recommendations about base
system conventions that do not apply.

Issue originally reported by semarie@, solution using
an idea from tedu@, discussed with jmc@ and jca@.

Revision 1.125 / (download) - annotate - [select for diffs], Sat Jun 17 23:06:43 2017 UTC (6 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.124: +7 -2 lines
Diff to previous 1.124 (colored)

style message about duplicate RCS ids; inspired by mdoclint

Revision 1.124 / (download) - annotate - [select for diffs], Sat Jun 17 22:40:27 2017 UTC (6 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.123: +44 -2 lines
Diff to previous 1.123 (colored)

style message about missing RCS ids; inspired by mdoclint

Revision 1.123 / (download) - annotate - [select for diffs], Tue Jun 13 15:05:22 2017 UTC (6 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.122: +3 -4 lines
Diff to previous 1.122 (colored)

Delete the arbitrary range restriction for -Owidth.
We provide users with tools.  We don't attempt to prevent them from
using them in stupid ways: depending on the context, not every
stupid-looking use is necessarily actually stupid, and not every
stupidity can be automatically detected anyway, so don't even try.

Revision 1.122 / (download) - annotate - [select for diffs], Sun Jun 11 17:16:36 2017 UTC (6 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.121: +11 -2 lines
Diff to previous 1.121 (colored)

style message about missing .Fn markup; inspired by mdoclint

Revision 1.121 / (download) - annotate - [select for diffs], Sat Jun 10 01:48:31 2017 UTC (6 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.120: +7 -2 lines
Diff to previous 1.120 (colored)

style message about missing blank before trailing delimiter;
inspired by mdoclint(1), and jmc@ considers it useful

Revision 1.120 / (download) - annotate - [select for diffs], Thu Jun 8 00:21:23 2017 UTC (6 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.119: +8 -2 lines
Diff to previous 1.119 (colored)

Portable mandoc just got a warning about unknown .Lb names
which we don't want in OpenBSD, but let's keep the message table
and the manual page in sync.

Revision 1.119 / (download) - annotate - [select for diffs], Wed Jun 7 23:29:31 2017 UTC (6 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.118: +32 -2 lines
Diff to previous 1.118 (colored)

style checks related to .Er; inspired by mdoclint(1)

Revision 1.118 / (download) - annotate - [select for diffs], Tue Jun 6 15:00:56 2017 UTC (6 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.117: +7 -2 lines
Diff to previous 1.117 (colored)

Minimal implementation of the roff(7) .ce request (center a number
of input lines without filling).
Contrary to groff, high-level macros abort .ce mode for now.

Revision 1.117 / (download) - annotate - [select for diffs], Sat Jun 3 12:16:19 2017 UTC (6 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.116: +4 -4 lines
Diff to previous 1.116 (colored)

enable -Wstyle by default in -Tlint; OK jmc@

Revision 1.116 / (download) - annotate - [select for diffs], Thu Jun 1 15:24:41 2017 UTC (6 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.115: +7 -2 lines
Diff to previous 1.115 (colored)

STYLE message about full stop at the end of .Nd; inspired by mdoclint(1)

Revision 1.115 / (download) - annotate - [select for diffs], Wed May 31 15:30:12 2017 UTC (6 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.114: +11 -1 lines
Diff to previous 1.114 (colored)

STYLE message about missing use of Ox/Nx/Fx/Dx; OK jmc@ wiz@

Revision 1.114 / (download) - annotate - [select for diffs], Tue May 30 20:20:45 2017 UTC (6 years, 11 months ago) by jmc
Branch: MAIN
Changes since 1.113: +4 -4 lines
Diff to previous 1.113 (colored)

tweak previous;

Revision 1.113 / (download) - annotate - [select for diffs], Tue May 30 19:29:31 2017 UTC (6 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.112: +13 -1 lines
Diff to previous 1.112 (colored)

STYLE message about useless macros we don't want (Bt Tn Ud);
not a WARNING because they don't endanger portability

Revision 1.112 / (download) - annotate - [select for diffs], Wed May 17 23:39:15 2017 UTC (7 years ago) by schwarze
Branch: MAIN
Changes since 1.111: +2 -5 lines
Diff to previous 1.111 (colored)

Delete the -T xhtml command line option.
It has been obsolete for more than two years.
Use -T html.

Revision 1.111 / (download) - annotate - [select for diffs], Wed May 17 23:20:00 2017 UTC (7 years ago) by schwarze
Branch: MAIN
Changes since 1.110: +2 -3 lines
Diff to previous 1.110 (colored)

Modernize an example showing antiquated syntax,
and delete an example showing the arcane -W stop option.

Revision 1.110 / (download) - annotate - [select for diffs], Tue May 16 19:35:25 2017 UTC (7 years ago) by jmc
Branch: MAIN
Changes since 1.109: +3 -3 lines
Diff to previous 1.109 (colored)

missing space between macro arg and punctuation;

Revision 1.109 / (download) - annotate - [select for diffs], Tue May 16 19:05:36 2017 UTC (7 years ago) by schwarze
Branch: MAIN
Changes since 1.108: +31 -12 lines
Diff to previous 1.108 (colored)

Introduce a new mandoc(1) message level, -W style, below -W warning.
Switch -W all from meaning -W warning to meaning -W style.
The meaning of -T lint does *not* change, it still implies -W warning.
No messages on the new level yet, but they will come.

Usually, i do not lightly make the user interface larger.
But this has been planned for years, and EXIT STATUS 1
was reserved for it all the time.  The message system
is now stable enough to finally implement it.

jmc@ regarding the concept: "really good idea"

Revision 1.108 / (download) - annotate - [select for diffs], Mon Mar 27 18:51:20 2017 UTC (7 years, 1 month ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_6_1_BASE, OPENBSD_6_1
Changes since 1.107: +4 -4 lines
Diff to previous 1.107 (colored)

simplify the SYNOPSIS as well, just like the option lists;
suggested by and OK jmc@

Revision 1.107 / (download) - annotate - [select for diffs], Mon Mar 27 15:16:46 2017 UTC (7 years, 1 month ago) by schwarze
Branch: MAIN
Changes since 1.106: +6 -16 lines
Diff to previous 1.106 (colored)

For some options that are rarely needed in mandoc(1),
delete the descriptions and point to man(1) instead.
Inspired by apropos.1 rev. 1.35.

Revision 1.106 / (download) - annotate - [select for diffs], Mon Mar 27 14:39:56 2017 UTC (7 years, 1 month ago) by schwarze
Branch: MAIN
Changes since 1.105: +5 -17 lines
Diff to previous 1.105 (colored)

Simplify: mention at one place that -fkl override each other,
rather than stating it separately for each option.
Suggested, OKed, and tweaked by jmc@.

Revision 1.105 / (download) - annotate - [select for diffs], Tue Mar 21 18:25:32 2017 UTC (7 years, 1 month ago) by schwarze
Branch: MAIN
Changes since 1.104: +3 -3 lines
Diff to previous 1.104 (colored)

simplify .Nd; to display manuals, use man(1) instead;
OK jmc@

Revision 1.104 / (download) - annotate - [select for diffs], Mon Mar 20 14:30:43 2017 UTC (7 years, 2 months ago) by schwarze
Branch: MAIN
Changes since 1.103: +31 -61 lines
Diff to previous 1.103 (colored)

Silently ignore invalid -m input formats rather than erroring out.
As observed by Jan Stary <hans at stare dot cz>, this is useful such
that after 'alias man="man -m $HOME/man"', 'man -l foo.1' still works.
Simplify and shorten the description of -m, and use .Ic for macros.

Revision 1.103 / (download) - annotate - [select for diffs], Sat Mar 18 19:50:58 2017 UTC (7 years, 2 months ago) by schwarze
Branch: MAIN
Changes since 1.102: +18 -5 lines
Diff to previous 1.102 (colored)

Correct description of MANPATH, and a few more improvements
to the ENVIRONMENT section; OK jmc@

Revision 1.102 / (download) - annotate - [select for diffs], Wed Mar 8 19:40:46 2017 UTC (7 years, 2 months ago) by schwarze
Branch: MAIN
Changes since 1.101: +12 -2 lines
Diff to previous 1.101 (colored)

Document that -T markdown produces ASCII output, and the implied
limitations.  Of course, we could write UTF-8 output instead,
but even the CommonMark specification doesn't require parsers
to support that, so portability would be doubtful.

While here, provide a link to the CommonMark specification.

Revision 1.101 / (download) - annotate - [select for diffs], Mon Mar 6 17:25:24 2017 UTC (7 years, 2 months ago) by schwarze
Branch: MAIN
Changes since 1.100: +10 -2 lines
Diff to previous 1.100 (colored)

Using .Nd only makes sense in the NAME section.
Warn if that macro occurs elsewhere.
Triggered by a question from Dag-Erling Smoergrav <des @ FreeBSD>.

Revision 1.100 / (download) - annotate - [select for diffs], Sat Mar 4 17:17:17 2017 UTC (7 years, 2 months ago) by schwarze
Branch: MAIN
Changes since 1.99: +21 -13 lines
Diff to previous 1.99 (colored)

Make the description of -K autodetection easer to understand.
Basic idea suggested by jmc@, OK jmc@.

Revision 1.99 / (download) - annotate - [select for diffs], Fri Mar 3 14:21:41 2017 UTC (7 years, 2 months ago) by schwarze
Branch: MAIN
Changes since 1.98: +33 -3 lines
Diff to previous 1.98 (colored)

new -mdoc -Tmarkdown output mode; OK millert@ reyk@ tb@;
thanks to reyk@ and to Vsevolod at FreeBSD for suggesting it

Revision 1.98 / (download) - annotate - [select for diffs], Fri Feb 10 15:44:31 2017 UTC (7 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.97: +15 -2 lines
Diff to previous 1.97 (colored)

In -Ttree output mode, show the BROKEN node flag and
provide a -Onoval output option to show the unvalidated tree.

Revision 1.97 / (download) - annotate - [select for diffs], Tue Jan 31 19:43:23 2017 UTC (7 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.96: +15 -2 lines
Diff to previous 1.96 (colored)

add missing HISTORY information

Revision 1.96 / (download) - annotate - [select for diffs], Sat Jan 28 23:26:55 2017 UTC (7 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.95: +6 -2 lines
Diff to previous 1.95 (colored)

Add a warning "new sentence, new line".
This does not attempt to pinpoint each and every offender, but
instead tries very hard to avoid false positives: Currently, there
are only two false positives in the whole OpenBSD base system.
Only do this in mdoc(7), not in man(7), because manuals written
in man(7) typically have much worse problems than this.
OK jmc@ on a previous version of the patch

Revision 1.95 / (download) - annotate - [select for diffs], Sat Jan 21 02:32:37 2017 UTC (7 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.94: +2 -11 lines
Diff to previous 1.94 (colored)

bug was fixed, delete the BUGS section

Revision 1.94 / (download) - annotate - [select for diffs], Thu Jan 12 17:29:34 2017 UTC (7 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.93: +11 -3 lines
Diff to previous 1.93 (colored)

show meta data for -Ttree output

Revision 1.93 / (download) - annotate - [select for diffs], Tue Jan 10 12:54:27 2017 UTC (7 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.92: +8 -2 lines
Diff to previous 1.92 (colored)

Introduce flags NODE_NOSRC and NODE_NOPRT for AST nodes.
Use them to mark generated nodes and nodes that shall not produce output.
Let -Ttree output mode display these new flags.
Use NODE_NOSRC for .Ar, .Mt, and .Pa default arguments.
Use NODE_NOPRT for .Dd, .Dt, and .Os.

These will help to make handling of text production macros more rigorous.

Revision 1.92 / (download) - annotate - [select for diffs], Sun Jan 8 00:10:22 2017 UTC (7 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.91: +14 -7 lines
Diff to previous 1.91 (colored)

Stricter validation of the NAME section, in particular:
- require a comma between names
- reject all other text nodes
- reject all empty Nm below NAME, not only in the leading position
- reject Nm after Nd

Revision 1.91 / (download) - annotate - [select for diffs], Fri Jan 6 01:33:48 2017 UTC (7 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.90: +5 -5 lines
Diff to previous 1.90 (colored)

sort options list; the same as jmc@ did in man.1 rev. 1.18

Revision 1.90 / (download) - annotate - [select for diffs], Wed Dec 28 18:30:56 2016 UTC (7 years, 4 months ago) by jmc
Branch: MAIN
Changes since 1.89: +3 -3 lines
Diff to previous 1.89 (colored)

spelling fix;

Revision 1.89 / (download) - annotate - [select for diffs], Wed Dec 28 17:21:17 2016 UTC (7 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.88: +9 -2 lines
Diff to previous 1.88 (colored)

Make the second, section number argument of .Xr mandatory.
In fact, we have been requiring it for many years.
The only reason to not warn when it was missing
was excessive traditionalism - it was optional in 4.4BSD.

Revision 1.88 / (download) - annotate - [select for diffs], Thu Nov 5 17:47:53 2015 UTC (8 years, 6 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_6_0_BASE, OPENBSD_6_0, OPENBSD_5_9_BASE, OPENBSD_5_9
Changes since 1.87: +5 -5 lines
Diff to previous 1.87 (colored)

simplify: use one stylesheet rather than two; from bentley@

Revision 1.87 / (download) - annotate - [select for diffs], Fri Oct 30 19:03:36 2015 UTC (8 years, 6 months ago) by schwarze
Branch: MAIN
Changes since 1.86: +8 -1 lines
Diff to previous 1.86 (colored)

If a .Bd block has no arguments at all, drop the block and only keep
its contents.  Removing a gratuitious difference to groff output
found after a related bug report from krw@.

Revision 1.86 / (download) - annotate - [select for diffs], Sat Sep 26 17:12:45 2015 UTC (8 years, 7 months ago) by jmc
Branch: MAIN
Changes since 1.85: +5 -4 lines
Diff to previous 1.85 (colored)

tweak previous;

Revision 1.85 / (download) - annotate - [select for diffs], Sat Sep 26 12:54:39 2015 UTC (8 years, 7 months ago) by schwarze
Branch: MAIN
Changes since 1.84: +42 -2 lines
Diff to previous 1.84 (colored)

briefly document -T tree output

Revision 1.84 / (download) - annotate - [select for diffs], Mon Sep 14 15:35:47 2015 UTC (8 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.83: +2 -9 lines
Diff to previous 1.83 (colored)

Remove the warning about children of .Vt blocks because actually,
.Vt type global_variable No = Dv defined_constant ;
is the best way to specify in the SYNOPSIS how a global variable
is initialized in the rare case where that matters.
Issue noticed by jmc@.

Revision 1.83 / (download) - annotate - [select for diffs], Fri Apr 3 08:45:27 2015 UTC (9 years, 1 month ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_5_8_BASE, OPENBSD_5_8
Changes since 1.82: +4 -3 lines
Diff to previous 1.82 (colored)

No need to hardcode /usr/bin/ as the path to more(1); helps portability.
We don't hardcode the paths to gunzip(1) and cmp(1) either.
Discussed with ajacoutot@.

Revision 1.82 / (download) - annotate - [select for diffs], Sun Mar 29 21:12:00 2015 UTC (9 years, 1 month ago) by bentley
Branch: MAIN
Changes since 1.81: +2 -2 lines
Diff to previous 1.81 (colored)

Escape punctuation characters that have a different meaning in -Tpdf.

~, `, and ' get translated to non-ASCII characters by most troff
implementations when generating PostScript/PDF output. When the original
ASCII character is meant, it needs to be manually escaped.

discussed with jmc@ schwarze@; ok schwarze@

Revision 1.81 / (download) - annotate - [select for diffs], Fri Mar 27 17:02:52 2015 UTC (9 years, 1 month ago) by jmc
Branch: MAIN
Changes since 1.80: +3 -3 lines
Diff to previous 1.80 (colored)

refering -> referring;

Revision 1.80 / (download) - annotate - [select for diffs], Fri Mar 27 16:35:57 2015 UTC (9 years, 1 month ago) by schwarze
Branch: MAIN
Changes since 1.79: +55 -58 lines
Diff to previous 1.79 (colored)

Modernize documentation by inserting blanks between option letters
and option arguments, except for -m because "-m an" and "-m andoc"
look just too weird.  Of course, the traditional form without the
blank will continue to work.

Revision 1.79 / (download) - annotate - [select for diffs], Mon Feb 23 13:30:02 2015 UTC (9 years, 2 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_5_7_BASE, OPENBSD_5_7
Changes since 1.78: +19 -9 lines
Diff to previous 1.78 (colored)

improve NAME section diagnostics;
confusing messages reported by Jan Stary <hans at stare dot cz>

Revision 1.78 / (download) - annotate - [select for diffs], Mon Feb 16 19:02:32 2015 UTC (9 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.77: +5 -2 lines
Diff to previous 1.77 (colored)

clean up post_dt() validation function;
improved diagnostics, minus six lines of code

Revision 1.77 / (download) - annotate - [select for diffs], Mon Feb 16 16:18:02 2015 UTC (9 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.76: +3 -5 lines
Diff to previous 1.76 (colored)

Delete the -V option.  It serves no purpose but keeps confusing people.

Revision 1.76 / (download) - annotate - [select for diffs], Tue Feb 10 07:40:27 2015 UTC (9 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.75: +1093 -2 lines
Diff to previous 1.75 (colored)

Explain all WARNING, ERROR, and UNSUPP messages in the DIAGNOSTICS section.
Feedback provided by jmc@ some time ago helped me to get this much
more concise than my initial attempt.
"i'm fine with it going in" jmc@

Revision 1.75 / (download) - annotate - [select for diffs], Thu Jan 29 00:33:14 2015 UTC (9 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.74: +9 -108 lines
Diff to previous 1.74 (colored)

Radical cleanup of COMPATIBILITY sections:
Remove lots of lies, dozens of irrelevant implementation details,
and all references to groff versions older than 1.17.  Move relevant
information to the pages where it belongs, and out of mandoc(1) in
particular.  Add some missing general remarks to roff(7), where it
fits the character and purpose of the page much better.

Revision 1.74 / (download) - annotate - [select for diffs], Tue Jan 20 22:02:15 2015 UTC (9 years, 3 months ago) by jmc
Branch: MAIN
Changes since 1.73: +3 -3 lines
Diff to previous 1.73 (colored)

tweak previous;

Revision 1.73 / (download) - annotate - [select for diffs], Tue Jan 20 21:12:46 2015 UTC (9 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.72: +34 -12 lines
Diff to previous 1.72 (colored)

Split the -Werror message level into -Werror (broken manual, probably
using mandoc is better than using groff) and -Wunsupp (manual using
unsupported low-level roff(7) feature, probably using groff is better
than using mandoc).  Once this feature is complete, it is intended
to help porting, making the decision whether to USE_GROFF easier.

As a first step, distinguish four classes of roff(7) requests:
1. Supported (currently 24 requests)
2. Currently ignored because unimportant (120)  ->  no message
3. Ignored for good because insecure (14)  ->  -Werror
4. Currently unsupported (68)  ->  these trigger the new -Wunsupp messages

Revision 1.72 / (download) - annotate - [select for diffs], Thu Jan 15 04:26:06 2015 UTC (9 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.71: +10 -15 lines
Diff to previous 1.71 (colored)

Fatal errors no longer exist.
If a file can be opened, mandoc will produce some output;
at worst, the output may be almost empty.
Simplifies error handling and frees a message type for future use.

Revision 1.71 / (download) - annotate - [select for diffs], Wed Jan 14 22:02:00 2015 UTC (9 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.70: +13 -9 lines
Diff to previous 1.70 (colored)

To get rid of SYSERR entries in enum mandocerr, downgrade problems with
missing and unreadable files from SYSERR to ERROR.
Needed for upcoming work.
As a bonus, this minimally simplifies code and documentation.

Revision 1.70 / (download) - annotate - [select for diffs], Sun Dec 28 14:39:08 2014 UTC (9 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.69: +5 -2 lines
Diff to previous 1.69 (colored)

mdoc(7) already uses the mandoc(1) -Ios argument in the footer line
when .Os has no argument, so do the same for man(7) when .TH has less
than four arguments; there is no reason to treat both differently.
Issue found following a question from Thomas Klausner <wiz at NetBSD>.

Revision 1.69 / (download) - annotate - [select for diffs], Mon Dec 15 17:36:47 2014 UTC (9 years, 5 months ago) by schwarze
Branch: MAIN
Changes since 1.68: +7 -3 lines
Diff to previous 1.68 (colored)

Merge from bsd.lv: text about HTML written by kristaps@.

Revision 1.68 / (download) - annotate - [select for diffs], Tue Dec 2 11:31:46 2014 UTC (9 years, 5 months ago) by schwarze
Branch: MAIN
Changes since 1.67: +9 -7 lines
Diff to previous 1.67 (colored)

Switch the default output mode from -Tascii to -Tlocale.
This doesn't change anything unless LC_CTYPE is set,
but it helps when running with LC_TYPE=something.UTF-8.

OK tedu@  and earlier positive feedback from:
bentley@ deraadt@ naddy@ stsp@  uqs@freebsd wiz@netbsd

Revision 1.67 / (download) - annotate - [select for diffs], Tue Nov 25 03:44:35 2014 UTC (9 years, 5 months ago) by bentley
Branch: MAIN
Changes since 1.66: +4 -12 lines
Diff to previous 1.66 (colored)

"Aq foo" is not the same as "<foo>". Don't use it to mark up HTML.

ok schwarze@

Revision 1.66 / (download) - annotate - [select for diffs], Tue Nov 11 02:43:11 2014 UTC (9 years, 6 months ago) by schwarze
Branch: MAIN
Changes since 1.65: +2 -2 lines
Diff to previous 1.65 (colored)

Let -h imply -c (that is, not use the pager).
Usually, -h output is short, so the pager is just a nuisance.
Also, traditional man(1) does not use a pager for -h.
Triggered by a remark of deraadt@ on ICB.

Revision 1.65 / (download) - annotate - [select for diffs], Thu Oct 30 15:05:05 2014 UTC (9 years, 6 months ago) by jmc
Branch: MAIN
Changes since 1.64: +3 -3 lines
Diff to previous 1.64 (colored)

mandoc.1: fix a macro error in previous
main.c: add -K to usage() and wrap nicely

ok schwarze

Revision 1.64 / (download) - annotate - [select for diffs], Thu Oct 30 00:05:02 2014 UTC (9 years, 6 months ago) by schwarze
Branch: MAIN
Changes since 1.63: +28 -2 lines
Diff to previous 1.63 (colored)

support UTF-8 and ISO-8859-1 input by integrating modified parts
of kristaps@' version of the preconv(1) utility into mandoc(1);
positive feedback from bentley@ and no concern raised when shown on tech@

Revision 1.63 / (download) - annotate - [select for diffs], Tue Oct 7 18:17:05 2014 UTC (9 years, 7 months ago) by schwarze
Branch: MAIN
Changes since 1.62: +9 -18 lines
Diff to previous 1.62 (colored)

Switch HTML output to polyglot HTML5; have only one single -Thml mode.
Replace hard-coded widths and alignments with a minimal embedded stylesheet.
Do not use <p> because it cannot appear inside block macros.
Remove the "summary" attribute because it is not HTML5.

Written by kristaps@ some months ago, finished during EuroBSDCon.

Revision 1.62 / (download) - annotate - [select for diffs], Wed Sep 3 05:17:08 2014 UTC (9 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.61: +7 -3 lines
Diff to previous 1.61 (colored)

Implement the traditional -h option for man(1): show the SYNOPSIS only.
As usual, we get mandoc -h and apropos -h for free.
Try stuff like "apropos -h In=dirent" or "apropos -h Fa=timespec".

Only useful for terminal output, so -Tps, -Tpdf, -Thtml ignore -h for now.

Revision 1.61 / (download) - annotate - [select for diffs], Sat Aug 30 18:04:52 2014 UTC (9 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.60: +40 -4 lines
Diff to previous 1.60 (colored)

Introduce a man(1) -l option as an alias for mandoc -a.
Basically, this does the same as man -l in Linux man-db.
The point is that now all functionality of the combined tool
is reachable from the man(1) command name:
apropos = man -k, whatis = man -f, mandoc = man -cl.

Originally suggested by Carsten dot Kunze at arcor dot de,
current maintainer of the Heirloom Documentation Tools.

While here, add various missing information to the usage()
and to the manuals.

Revision 1.60 / (download) - annotate - [select for diffs], Wed Aug 27 00:06:08 2014 UTC (9 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.59: +33 -3 lines
Diff to previous 1.59 (colored)

Add an implementation of man(1) into the /usr/bin/mandoc binary and
provide a unified set of command line options for mandoc(1), man(1),
apropos(1), and whatis(1), each option doing the same for all four.
Not adding any completely new options, only extending exiting ones
from one tool to the others.  New options are:
* apropos & whatis -acfkw  (in the past, these were man(1) only)
* apropos & whatis -a -IOTW  (in the past, mandoc(1) only)
* mandoc -ac  (in the past, man(1) only)
* man -IOTW  (in the past, mandoc(1) only)

Before we can decide whether or not we want to replace src/usr.bin/man
with this implementation, considerable bugfixing, testing, and
performance measurements are needed, which i'd rather do in the tree
than outside.  Note that these bugs only affect the new man(1) mode,
existing mandoc(1), apropos(1), and whatis(1) is fine.

The new functionality in mandoc(1), apropos(1), and whatis(1)
is fully enabled.  To play with the new man(1), you can try:
# mv /usr/bin/man /usr/bin/oman
# ln -s /usr/bin/mandoc /usr/bin/man

Positive feedback about the general direction from sthen@ and jmc@,
and deraadt@ is not against it.

Revision 1.59 / (download) - annotate - [select for diffs], Fri Aug 8 16:25:15 2014 UTC (9 years, 9 months ago) by schwarze
Branch: MAIN
Changes since 1.58: +15 -30 lines
Diff to previous 1.58 (colored)

Remove redundant verbiage in the style of "a file is a file,
a line is a line, a column is a column"; suggested by jmc@

Revision 1.58 / (download) - annotate - [select for diffs], Mon Jun 23 22:03:03 2014 UTC (9 years, 10 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_5_6_BASE, OPENBSD_5_6
Changes since 1.57: +7 -4 lines
Diff to previous 1.57 (colored)

Below DIAGNOSTICS, document the SYSERR message level;
jmc@ wondered what it meant and agrees with this patch.

Revision 1.57 / (download) - annotate - [select for diffs], Fri Jun 20 22:58:41 2014 UTC (9 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.56: +10 -6 lines
Diff to previous 1.56 (colored)

As suggested by jmc@, only include line and column numbers into messages
when they are meaningful, to avoid confusing stuff like this:
$ mandoc /dev/null
mandoc: /dev/null:0:1: FATAL: not a manual
Instead, just say:
mandoc: /dev/null: FATAL: not a manual

Another example this applies to is documents having a prologue,
but lacking a body.  Do not throw a FATAL error for these; instead,
issue a warning and show the empty document, in the man(7) case with
the same amount of blank lines as groff does.  Also downgrade mdoc(7)
documents having content before the first .Sh from FATAL to WARNING.

Revision 1.56 / (download) - annotate - [select for diffs], Sat Jul 13 19:27:46 2013 UTC (10 years, 10 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_5_5_BASE, OPENBSD_5_5, OPENBSD_5_4_BASE, OPENBSD_5_4
Changes since 1.55: +3 -4 lines
Diff to previous 1.55 (colored)

For citing the names and email addresses of authors,
consistently use the style ".An name Aq Mt email".

Triggered by a question from Jan Stary <hans at stare dot cz>,
ok jmc@.

Revision 1.55 / (download) - annotate - [select for diffs], Wed Mar 6 06:54:14 2013 UTC (11 years, 2 months ago) by jmc
Branch: MAIN
Changes since 1.54: +3 -3 lines
Diff to previous 1.54 (colored)

legancy -> legacy; From: Chris Hettrick

Revision 1.54 / (download) - annotate - [select for diffs], Thu May 24 23:33:23 2012 UTC (11 years, 11 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_5_3_BASE, OPENBSD_5_3, OPENBSD_5_2_BASE, OPENBSD_5_2
Changes since 1.53: +14 -2 lines
Diff to previous 1.53 (colored)

Support -Ios='OpenBSD 5.1' to override uname(3) as the source of the
default value for the mdoc(7) .Os macro.
Needed for man.cgi on the OpenBSD website.

Problem with man.cgi first noticed by deraadt@;
beck@ and deraadt@ agree with the way to solve the issue.

Revision 1.53 / (download) - annotate - [select for diffs], Sun Dec 25 20:15:54 2011 UTC (12 years, 4 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_5_1_BASE, OPENBSD_5_1
Changes since 1.52: +14 -13 lines
Diff to previous 1.52 (colored)

State default usage before listing arguments of a utility;
from kristaps@, ok jmc@.

Revision 1.52 / (download) - annotate - [select for diffs], Sun Nov 13 14:38:57 2011 UTC (12 years, 6 months ago) by jmc
Branch: MAIN
Changes since 1.51: +3 -3 lines
Diff to previous 1.51 (colored)

overful -> overfull;

Revision 1.51 / (download) - annotate - [select for diffs], Sun Nov 13 13:05:23 2011 UTC (12 years, 6 months ago) by schwarze
Branch: MAIN
Changes since 1.50: +10 -1 lines
Diff to previous 1.50 (colored)

Make the default left text margin configurable from the command line,
just like the default right margin already is.  This may be useful for
people with expensive screen real estate.  Besides, it helps automated
man(7) to mdoc(7) output comparisons to validate -Tman output.
ok kristaps@ on an earlier version

Revision 1.50 / (download) - annotate - [select for diffs], Sun Oct 9 21:37:04 2011 UTC (12 years, 7 months ago) by schwarze
Branch: MAIN
Changes since 1.49: +22 -9 lines
Diff to previous 1.49 (colored)

A bit more precision and nicer wording in the descriptions
of -Ofragment and -Tman; using input from jmc@ and kristaps@.

Revision 1.49 / (download) - annotate - [select for diffs], Sun Oct 9 17:59:56 2011 UTC (12 years, 7 months ago) by schwarze
Branch: MAIN
Changes since 1.48: +32 -6 lines
Diff to previous 1.48 (colored)

Sync to version 1.12.0; all code by kristaps@:
Implement .Rv in -Tman.
Let -man -Tman work a bit like cat(1).
Add the -Ofragment option to -T[x]html.
Minor fixes in -T[x]html.
Lots of apropos(1) and -Tman code cleanup.

Revision 1.48 / (download) - annotate - [select for diffs], Mon Sep 26 14:49:03 2011 UTC (12 years, 7 months ago) by jmc
Branch: MAIN
Changes since 1.47: +35 -35 lines
Diff to previous 1.47 (colored)

retain alphabetical order for the -Toutput list, and use a width
specifier that makes it look nicer;

ok schwarze kristaps

Revision 1.47 / (download) - annotate - [select for diffs], Sun Sep 18 10:25:28 2011 UTC (12 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.46: +5 -3 lines
Diff to previous 1.46 (colored)

sync to version 1.11.5:
adding an implementation of the eqn(7) language
by kristaps@

So far, only .EQ/.EN blocks are handled, in-line equations are not, and
rendering is not yet very pretty, but the parser is fairly complete.

Revision 1.46 / (download) - annotate - [select for diffs], Sat Sep 17 14:45:22 2011 UTC (12 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.45: +18 -2 lines
Diff to previous 1.45 (colored)

Initial, incomplete support for -Tman
to convert mdoc(7) documents to the man(7) language.
This is work in progress and will be developed in tree.
It does already handle the cat(1) manual,
but will hardly handle all your fancy manuals yet.
go ahead  kristaps@ jmc@ millert@ deraadt@

Revision 1.45 / (download) - annotate - [select for diffs], Tue May 31 22:44:48 2011 UTC (12 years, 11 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_5_0_BASE, OPENBSD_5_0
Changes since 1.44: +9 -10 lines
Diff to previous 1.44 (colored)

Minor fixes by kristaps@, based on issues reported by jmc@.

Revision 1.44 / (download) - annotate - [select for diffs], Sun May 29 21:22:18 2011 UTC (12 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.43: +40 -6 lines
Diff to previous 1.43 (colored)

Merge release 1.11.3, almost all code by kristaps@:
* Unicode output support (no Unicode input yet, though).
* Refactoring: completely handle predefined strings in roff.c.
- New function mandoc_escape() replaces a2roffdeco() and mandoc_special().
- Start using mandoc_getarg() in mdoc_argv.c.
- Clean up parsing of delimiters in mdoc(7).
* And many minor fixes and lots of cleanup.

Revision 1.43 / (download) - annotate - [select for diffs], Sun Jan 9 15:24:57 2011 UTC (13 years, 4 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_4_9_BASE, OPENBSD_4_9
Changes since 1.42: +5 -3 lines
Diff to previous 1.42 (colored)

Add and install tbl(7);
written by kristaps@, looked over by jmc@.

Revision 1.42 / (download) - annotate - [select for diffs], Wed Dec 22 00:33:25 2010 UTC (13 years, 5 months ago) by schwarze
Branch: MAIN
Changes since 1.41: +15 -24 lines
Diff to previous 1.41 (colored)

More small -Thtml improvements by kristaps@,
in particular, use <B>, <I> and <U> where appropriate.
Provide relative widths for header and footer lines.
Manuals: More concise short descriptions of output modes.
Correct a few places still talking about CSS2 to say CSS1.
Code examples should use .Dl, not .D1.

Revision 1.41 / (download) - annotate - [select for diffs], Sun Dec 19 09:22:35 2010 UTC (13 years, 5 months ago) by schwarze
Branch: MAIN
Changes since 1.40: +1 -10 lines
Diff to previous 1.40 (colored)

Significant improvements to -Thtml by kristaps@:
Use less <DIV>, use more <H1>, <H2>, <P>, <BR>, <PRE>, <UL>, <OL>, <DL> etc.
Triggered by input from Will Backman.
Remove CSS2 note in mandoc.1, which is no longer true.

Revision 1.40 / (download) - annotate - [select for diffs], Sun Sep 26 22:39:38 2010 UTC (13 years, 7 months ago) by jmc
Branch: MAIN
Changes since 1.39: +4 -4 lines
Diff to previous 1.39 (colored)

new sentence, new line;

Revision 1.39 / (download) - annotate - [select for diffs], Sun Sep 26 19:54:35 2010 UTC (13 years, 7 months ago) by schwarze
Branch: MAIN
Changes since 1.38: +4 -18 lines
Diff to previous 1.38 (colored)

sync to bsd.lv:
do not talk about \s, it is ignored anyway
do not .Xr groff(1) any longer, just talk about GNU troff
because in the long run, groff may not even be installed

Revision 1.38 / (download) - annotate - [select for diffs], Fri Aug 20 00:53:35 2010 UTC (13 years, 9 months ago) by schwarze
Branch: MAIN
Changes since 1.37: +144 -60 lines
Diff to previous 1.37 (colored)

Implement a simple, consistent user interface for error handling.
We now have sufficient practical experience to know what we want,
so this is intended to be final:
- provide -Wlevel (warning, error or fatal) to select what you care about
- provide -Wstop to stop after parsing a file with warnings you care about
- provide consistent exit status codes for those warnings you care about
- fully document what warnings, errors and fatal errors mean
- remove all other cruft from the user interface, less is more:
- remove all -f knobs along with the whole -f option
- remove the old -Werror because calling warnings "fatal" is silly
- always finish parsing each file, unless fatal errors prevent that
This commit also includes a couple of related simplifications behind
the scenes regarding error handling.
Feedback and OK  kristaps@;  Joerg Sonnenberger (NetBSD) and
Sascha Wildner (DragonFly BSD) agree with the general direction.

Revision 1.37 / (download) - annotate - [select for diffs], Wed Aug 18 01:35:01 2010 UTC (13 years, 9 months ago) by schwarze
Branch: MAIN
Changes since 1.36: +2 -12 lines
Diff to previous 1.36 (colored)

Remove mandoc(1) compatibility notes that are no longer relevant;
from kristaps@.

Revision 1.36 / (download) - annotate - [select for diffs], Sun Jul 25 18:05:54 2010 UTC (13 years, 9 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_4_8_BASE, OPENBSD_4_8
Changes since 1.35: +14 -2 lines
Diff to previous 1.35 (colored)

Sync to bsd.lv; in particular, pull in lots of bug fixes.
new features:
* support the .in macro in man(7)
* support minimal PDF output
* support .Sm in mdoc(7) HTML output
* support .Vb and .nf in man(7) HTML output
* complete the mdoc(7) manual
bug fixes:
* do not let mdoc(7) .Pp produce a newline before/after .Sh; reported by jmc@
* avoid double blank lines related to man(7) .sp and .br
* let man(7) .nf and .fi flush the line; reported by jsg@ and naddy@
* let "\ " produce a non-breaking space; reported by deraadt@
* discard \m colour escape sequences; reported by J.C. Roberts
* map undefined 1-character-escapes to the literal character itself
maintenance:
* express mdoc(7) arguments in terms of an enum for additional type-safety
* simplify mandoc_special() and a2roffdeco()
* use strcspn in term_word() in place of a manual loop
* minor optimisations in the -Tps and -Thtml formatting frontends

Revision 1.35 / (download) - annotate - [select for diffs], Tue Jul 13 01:09:13 2010 UTC (13 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.34: +16 -5 lines
Diff to previous 1.34 (colored)

Merge release 1.10.4 (all code by kristaps@), providing four new features:
1) Proper .Bk support: allow output line breaks at input line breaks,
but keep input lines together in the output, finally fixing
synopses like aucat(1), mail(1) and tmux(1).
2) Mostly finished -Tps (PostScript) output.
3) Implement -Thtml output for .Nm blocks and .Bk -words.
4) Allow iterative interpolation of user-defined roff(7) strings.
Also contains some minor bugfixes and some performance improvements.

Revision 1.34 / (download) - annotate - [select for diffs], Tue Jun 29 15:49:52 2010 UTC (13 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.33: +108 -142 lines
Diff to previous 1.33 (colored)

sync to bsd.lv version 1.10.3:
* support -Tps -Opaper=a4 and -Opaper=letter
* lots of mandoc.1 manual improvements

Revision 1.33 / (download) - annotate - [select for diffs], Tue Jun 29 14:41:28 2010 UTC (13 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.32: +15 -9 lines
Diff to previous 1.32 (colored)

framework for glyph width encoding; from kristaps@

Revision 1.32 / (download) - annotate - [select for diffs], Sat Jun 26 17:56:43 2010 UTC (13 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.31: +3 -3 lines
Diff to previous 1.31 (colored)

merge release 1.10.2
* bug fixes:
- interaction of ASCII_HYPH with special chars (found by Ulrich Spoerlein)
- handling of roff conditionals (found by Ulrich Spoerlein)
- .Bd -offset will no more default to 6n
* maintenance:
- more caching of .Bd and .Bl arguments for efficiency
- deconstify man(7) validation routines
- add FreeBSD library names (provided by Ulrich Spoerlein)
* start PostScript font-switching

Revision 1.31 / (download) - annotate - [select for diffs], Thu Jun 10 22:50:10 2010 UTC (13 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.30: +11 -2 lines
Diff to previous 1.30 (colored)

minimal initial -Tps support, from kristaps@ GSOC
so far, monospace without font decoration,
but it already has page headers and footers

Revision 1.30 / (download) - annotate - [select for diffs], Tue Jun 8 00:11:47 2010 UTC (13 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.29: +14 -4 lines
Diff to previous 1.29 (colored)

Merge more bits that will be going into 1.10.1:

Clean up vertical spacing in the SYNOPSIS, making the code much more
systematic; this doesn't solve all SYNOPSIS problems yet, in particular
not those related to keeps, indentation and the low-level .nr roff
instruction, but it's a nice step forward and i couldn't find relevant
regressions.  (from kristaps)

Besides,
* make the output width configurable (default: -Owidth=80) (kristaps)
* use mmap with MAP_SHARED (from Joerg Sonnenberger)

Revision 1.29 / (download) - annotate - [select for diffs], Fri May 14 01:54:37 2010 UTC (14 years ago) by schwarze
Branch: MAIN
Changes since 1.28: +4 -4 lines
Diff to previous 1.28 (colored)

merge 1.9.24, keeping local patches; some changes:
* preserve multiple consecutive space characters in input
* do not restrict .Cd and .Rv to certain sections (requested by Joerg)
* do not run lookup() on quoted words
* enum return types for mdoc_args and mdoc_argv
* fix auto-closing of LINK tag in -Txhtml (from Daniel Friesel)
* various lint and manual fixes

Revision 1.28 / (download) - annotate - [select for diffs], Thu May 13 20:34:29 2010 UTC (14 years ago) by schwarze
Branch: MAIN
Changes since 1.27: +3 -6 lines
Diff to previous 1.27 (colored)

Remove the command line option -fno-ign-chars.
This option was not useful, you never want mandoc to die
just because there is an invalid character in the input file,
neither in production nor when linting: a warning is sufficient.
This was particularly annoying because it was part of -fstrict
and could not be switched off.
"less is more" kristaps@

Revision 1.27 / (download) - annotate - [select for diffs], Tue Apr 13 08:52:23 2010 UTC (14 years, 1 month ago) by jmc
Branch: MAIN
Changes since 1.26: +2 -78 lines
Diff to previous 1.26 (colored)

zap all the (rather useless) dot lines; ok kristaps

Revision 1.26 / (download) - annotate - [select for diffs], Tue Apr 13 06:52:12 2010 UTC (14 years, 1 month ago) by jmc
Branch: MAIN
Changes since 1.25: +94 -95 lines
Diff to previous 1.25 (colored)

- sort everything
- prefer Cm to Ar for stuff like -Tascii
- fix wonky ellipsis
- standard $ prompt
- update usage()

kristaps has these diffs rolled in already
ok schwarze kristaps

Revision 1.25 / (download) - annotate - [select for diffs], Thu Apr 8 16:47:28 2010 UTC (14 years, 1 month ago) by jmc
Branch: MAIN
Changes since 1.24: +66 -36 lines
Diff to previous 1.24 (colored)

first pass at cleaning this page up:

- add openbsd rcsid
- new sentence, new line
- > -> \*(Gt

ok schwarze
diff sent to kristaps; this commit includes a tweak from kristaps to
keep the page up to date

Revision 1.24 / (download) - annotate - [select for diffs], Mon Mar 29 22:56:52 2010 UTC (14 years, 1 month ago) by schwarze
Branch: MAIN
Changes since 1.23: +11 -2 lines
Diff to previous 1.23 (colored)

merge 1.9.19, keeping local patches
 * scoping fixes for roff instructions
 * accept apostroph in place of dot as a macro control character
 * accept tabs between the control character and the macro name
 * check that man(7) .TH titles use capital letters

Revision 1.23 / (download) - annotate - [select for diffs], Fri Mar 26 01:22:05 2010 UTC (14 years, 1 month ago) by schwarze
Branch: MAIN
Changes since 1.22: +17 -4 lines
Diff to previous 1.22 (colored)

merge 1.9.17, keeping local patches

* much improved pod2man support and low-level roff robustness
* have -Tlint imply -Wall and -fstrict
* use fewer macros and more enum in libman
* and various bug fixes

Revision 1.22 / (download) - annotate - [select for diffs], Thu Mar 25 23:23:01 2010 UTC (14 years, 1 month ago) by schwarze
Branch: MAIN
Changes since 1.21: +16 -4 lines
Diff to previous 1.21 (colored)

merge 1.9.16, keeping local patches

This is mostly cleanup by kristaps@ after my rather hackish patch
to tolerate the non-text macros .na, .sp, .br in next-line scope;
plus some nesting issues fixed by him, all in man(7).
This survived a full  cd /usr/src; make man.

Revision 1.21 / (download) - annotate - [select for diffs], Thu Feb 18 02:11:26 2010 UTC (14 years, 3 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_4_7_BASE, OPENBSD_4_7
Changes since 1.20: +37 -16 lines
Diff to previous 1.20 (colored)

sync to release 1.9.15:
 * corrected .Vt handling (spotted by Joerg Sonnenberger)
 * corrected .Xr argument handling (based on my patch)
 * removed \\ escape sequence (because it is for low-level roff only)
 * warn about trailing whitespace (suggested by jmc@)
 * -Txhtml support
 * and some general cleanup and doc improvements

Revision 1.20 / (download) - annotate - [select for diffs], Thu Dec 24 02:08:14 2009 UTC (14 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.19: +140 -55 lines
Diff to previous 1.19 (colored)

sync to 1.9.14: rewrite escape sequence handling:
- new function a2roffdeco
- font modes (\f) only affect the current stack point
- implement scaling (\s)
- implement space suppression (\c)
- implement non-breaking space (\~) in -Tascii
- many manual improvements

Revision 1.19 / (download) - annotate - [select for diffs], Tue Dec 22 23:58:00 2009 UTC (14 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.18: +7 -2 lines
Diff to previous 1.18 (colored)

sync to 1.9.12, mostly portability and refactoring:

correctness/functionality:
- bugfix: do not die when overstep hits the right margin
- new option: -fign-escape
- and various HTML features

portability:
- replace bzero(3) by memset(3), which is ANSI C
- replace err(3)/warn(3) by perror(3)/exit(3), which is ANSI C
- iuse argv[0] instead of __progname
- add time.h to various files for FreeBSD compilation

simplicity:
- do not allocate header/footer data dynamically in *_term.c
- provide and use malloc frontends that error out on failure

for full changelogs, see http://bsd.lv/cgi-bin/cvsweb.cgi/

Revision 1.18 / (download) - annotate - [select for diffs], Tue Oct 27 21:40:07 2009 UTC (14 years, 6 months ago) by schwarze
Branch: MAIN
Changes since 1.17: +8 -8 lines
Diff to previous 1.17 (colored)

sync to 1.9.11: adapt printing of dates to groff conventions,
NetBSD portability fixes and some minor bugfixes and feature enhancements;
also checked that my hyphenation code still works on top of this

Revision 1.17 / (download) - annotate - [select for diffs], Wed Oct 21 19:13:50 2009 UTC (14 years, 7 months ago) by schwarze
Branch: MAIN
Changes since 1.16: +86 -16 lines
Diff to previous 1.16 (colored)

sync to 1.9.9, featuring:
 * -Thtml output mode
 * roff scaling units
 * and some minor fixes
for full changelogs, see http://bsd.lv/cgi-bin/cvsweb.cgi/

Revision 1.16 / (download) - annotate - [select for diffs], Fri Sep 18 22:46:14 2009 UTC (14 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.15: +4 -6 lines
Diff to previous 1.15 (colored)

sync to 1.9.2: Add .UC libman macro for compatibility, has no effect.
Correct .UC and .DT to not print their arguments.
Document that .UC and .DT should not be used.

Revision 1.15 / (download) - annotate - [select for diffs], Fri Sep 18 22:41:24 2009 UTC (14 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.14: +2 -2 lines
Diff to previous 1.14 (colored)

fix typo (overriden -> overridden); from jmc@; included in 1.9.2

Revision 1.14 / (download) - annotate - [select for diffs], Sat Aug 22 23:17:40 2009 UTC (14 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.13: +96 -47 lines
Diff to previous 1.13 (colored)

another large chunk of -man updates,
among others regarding .DT, .HP, .RS, .RE, .SH, .SS, and scoping,
now in sync vith release 1.9.1

Revision 1.13 / (download) - annotate - [select for diffs], Sat Aug 22 16:03:14 2009 UTC (14 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.12: +11 -4 lines
Diff to previous 1.12 (colored)

sync to 1.8.5: note that \~ does not work;
noticed by <uqs at spoerlein dot net>

Revision 1.12 / (download) - annotate - [select for diffs], Sat Aug 22 14:56:03 2009 UTC (14 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.11: +11 -1 lines
Diff to previous 1.11 (colored)

sync to 1.8.4: add option -fign-errors to check several manual pages
without stopping at errors

Revision 1.11 / (download) - annotate - [select for diffs], Sun Aug 9 20:40:18 2009 UTC (14 years, 9 months ago) by schwarze
Branch: MAIN
Changes since 1.10: +8 -8 lines
Diff to previous 1.10 (colored)

sync to 1.8.3: quote macro names without a preceding dot

Revision 1.10 / (download) - annotate - [select for diffs], Sun Aug 9 17:20:17 2009 UTC (14 years, 9 months ago) by schwarze
Branch: MAIN
Changes since 1.9: +38 -38 lines
Diff to previous 1.9 (colored)

sync to 1.8.2: remove trailing whitespace

Revision 1.9 / (download) - annotate - [select for diffs], Sat Jul 18 20:50:37 2009 UTC (14 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.8: +2 -10 lines
Diff to previous 1.8 (colored)

sync to 1.8.0: support .Bl -hang

Revision 1.8 / (download) - annotate - [select for diffs], Sun Jul 12 22:44:45 2009 UTC (14 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.7: +5 -9 lines
Diff to previous 1.7 (colored)

sync to 1.7.23: Fewer knobs: provide -Wall -Werror but not -Wsyntax -Wcompat.
The simplification of the internal code has already been done before,
this is just the user interface adjustment.

Revision 1.7 / (download) - annotate - [select for diffs], Tue Jun 23 23:40:59 2009 UTC (14 years, 10 months ago) by schwarze
Branch: MAIN
CVS Tags: OPENBSD_4_6_BASE, OPENBSD_4_6
Changes since 1.6: +18 -7 lines
Diff to previous 1.6 (colored)

sync to 1.7.20: Document whitespace handling.
Currently, mandoc(1) produces French spacing, which is a bug and needs
to be fixed, but document it anyway for the time being.
While here, fix a few typos, also reported upstream.

Revision 1.6 / (download) - annotate - [select for diffs], Sun Jun 21 20:03:11 2009 UTC (14 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.5: +27 -35 lines
Diff to previous 1.5 (colored)

sync to 1.7.19: update and reorder COMPATIBILITY and CAVEATS

Revision 1.5 / (download) - annotate - [select for diffs], Wed Jun 17 22:37:04 2009 UTC (14 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.4: +4 -4 lines
Diff to previous 1.4 (colored)

use standard Ds (eight char) indents for tab lists documenting options;
ok kristaps@

Revision 1.4 / (download) - annotate - [select for diffs], Sun Jun 14 23:39:43 2009 UTC (14 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.3: +6 -2 lines
Diff to previous 1.3 (colored)

sync to 1.7.16: support -V command line option

Revision 1.3 / (download) - annotate - [select for diffs], Sun Jun 14 23:00:57 2009 UTC (14 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.2: +14 -16 lines
Diff to previous 1.2 (colored)

sync to 1.7.16: comments, whitespace and spelling fixes; no functional change

Revision 1.2 / (download) - annotate - [select for diffs], Sat Apr 11 17:15:47 2009 UTC (15 years, 1 month ago) by deraadt
Branch: MAIN
Changes since 1.1: +3 -3 lines
Diff to previous 1.1 (colored)

uppercase Dt, ok jmc

Revision 1.1 / (download) - annotate - [select for diffs], Mon Apr 6 20:30:40 2009 UTC (15 years, 1 month ago) by kristaps
Branch: MAIN

Initial check-in of mandoc for formatting manuals. ok deraadt@

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.