Dear docutils developers,
I received two bug reports in Debian regarding the content of .TH macro in man pages:
First bug — https://bugs.debian.org/1016527 — asks that the value of --date argument be used for the third argument of .TH, instead of putting it on a separate line (Generated on: YYYY-MM-DD).
Second bug — https://bugs.debian.org/1018737 — asks that docutils not set fifth argument of .TH to empty string, but omit it completely and rely on the default value.
Please see those bugs for more detailed descriptions (and some discussion, in the first bug).
Thank you for forwarding the bug reports.
The "--date" command line argument (and "datestamp" configuration value) "Include a time/datestamp in the document footer." (https://docutils.sourceforge.io/docs/user/config.html#datestamp). They are generic Docutils options that should not be used with the
"manpage" writer.
The "date" value for the
.thmacro fetched from the "Date" field of the docinfo. See the test input "standalone_rst_manpage.txt" for an example.Regarding the second bug: will omitting the fifth argument of
.THwork with all troff/manpage processors?I asked the original reporter. He answered:
mqDmitry
I sometime test layout groff and try with mandoc what are the "others" ?
Pandoc seems to have its own manpage reader: https://github.com/jgm/pandoc/blob/master/src/Text/Pandoc/Readers/Man.hs.
the values in the roff header .TH
are taken from title and the docinfo
the Version is put into "source" ... don't know why I did this ?
No one ever complained.
So there should be a "Manual source" instead.
"Manual manual" sounds ... silly doesn't it so it is "Manual group"
Revision 9200 Does not output empty "manual" in
.THcould be set via docinfo[Manual group]
Last edit: engelbert gruber 2022-11-02
@grubert 9 tests are now failing in
test_manpage.py-- I think the test expectations need to be updated.A
sorry , fixed
Is there still work to do or can we set this issue to "open-fixed" and close it once 0.20 is out?
set to open-fixed
commandline --date is not usable, but docinfo-date is used
noone complained about the value of source or answered so I will leave it
there
On Thu, 20 Apr 2023 at 18:47, "Günter Milde" milde@users.sourceforge.net
wrote:
Related
Bugs:
#458One of the original bugs in Debian is fixed now. Regarding the other bug, I have forwarded your response to the original reporter, but he has not replied. So yes, I think you can close this bug.