Man pages: fix broken tables

Work around a go-md2man bug, and add a check script to make sure
this doesn't hit us again.

Background: go-md2man can't deal with a left-hand column > 31 chars.
It produces man pages that look like:

    | Something With >31 Character |                |
    |                              | ..description  |

(should be all on one row). It also has trouble when the vertical
bars are misaligned: it completely removes the right-hand side.

There's almost certainly a better solution: fix go-md2man, or
use a different conversion tool, or maybe even pre/postprocess.
But this is a quick interim solution.

Sorry for the perl. This could be done in bash/sed/awk/grep,
but not with any sort of sane error messages.

Signed-off-by: Ed Santiago <santiago@redhat.com>
This commit is contained in:
Ed Santiago
2023-05-24 11:21:48 -06:00
parent e7ef259cb6
commit dfba6ddd4c
4 changed files with 241 additions and 64 deletions

View File

@ -505,6 +505,7 @@ podman-remote-%-docs: podman-remote
man-page-check: bin/podman
hack/man-page-checker
hack/xref-helpmsgs-manpages
hack/man-page-table-check
.PHONY: swagger-check
swagger-check: