specify the date of the last change
Dd month day, year
macro (document date) is the first
macro in every
document. This page discusses date formats in detail, in the order of
In manuals for portable software, always use this format:
This format works with mandoc, GNU troff, and the Heirloom Doctools.
Note that month
are separate arguments, and the comma
follows the day
argument without intervening
Giving the whole date as a single argument, for example by quoting it, is
strongly discouraged. It fails with both GNU troff and Heirloom and only works
year” \" NOT
Even though many other macros require giving punctuation as separate arguments,
macro does not accept that.
Separating the comma from the day fails with both GNU troff and Heirloom and
even misformats slightly with mandoc:
month day ,
In OpenBSD base system manuals, always use this special format:
When committing, the
will rewrite this line as follows:
Note that this format does not
have a comma after
As usual with
text between the substitution keyword
and the trailing dollar sign is
removed and replaced at commit time.
This format is not fully portable. It is fully supported by mandoc, but GNU
troff only supports it since version 1.22.3 (November 2014), and the Heirloom
Doctools don't support it at all.
In the past, many
used the traditional format:
\" NOT PORTABLE!
This format is no longer recommended. Neither GNU troff nor the Heirloom
Doctools support it; only mandoc accepts it for backward compatibility.
While mandoc renders any non-empty arguments as given on the
line, relying on that behaviour is
strongly discouraged; it is not at all portable.
If they do not support the format, both GNU troff and the Heirloom Doctools show
the current date instead of whatever arguments are given. When no arguments
are given at all, even mandoc shows the current date.
For basic usage of the
macro, see the
MACRO REFERENCE section in the