17 Commits

Author SHA1 Message Date
b8c1a8e79d Apply suggestions from code review
Co-authored-by: Tom Sweeney <tsweeney@redhat.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2024-02-20 05:38:19 -05:00
8cbbd631d3 Fix up example description of podman-history.1.md
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2024-02-17 13:54:16 -05:00
3a9d14d4e9 man page --format xref: tighten the autocompletion check
Followup to #17486: stricter checks on --format.

  * If a subcommand offers autocompletion for templates,
    it must also offer a '--format json' option.

  * If a subcommand has a --format option that DOES NOT
    offer autocompletion for templates, it must be listed
    in a hardcoded grandparented-in table of commands
    where that's not applicable. (Mostly commands
    like build, commit, save, where "format" is used
    in the context of "oci/docker").

Only likely to trigger on PRs which add new subcommands,
and is intended to catch oversights.

Also, test for alphanumeric order in man page tables.
Sort all existing tables.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-02-14 08:11:54 -07:00
4334135491 [CI:DOCS] man-page checker: include --format (Go templates)
Very belated successor to #14046.

I don't know why this is so important to me. Probably because we're
doing a halfhearted sloppy job of documenting, and new options get
added, and not documented, and that's just wrong.

I've given up on documenting internal structs. This iteration
has a $Format_Exceptions table defined at the top of the xref
script, enumerating a hardcoded defined set of podman commands
and fields that should remain undocumented.

This iteration also forgives completely-undocumented formats.
If podman-foo has a --format, but podman-foo.1.md does not
list *any* valid fields, the script warns but does not fail.
This at least is better than documenting a random mix of fields.

This version of the xref script is much slower: 10s vs 4. I
think we can live with that in a CI-only script.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-02-08 15:33:45 -07:00
63c779a857 Fix manpage headers
Signed-off-by: Andrew Denton <adenton@redhat.com>
2022-09-06 09:37:13 -07:00
e76a07087e [CI:DOCS] man pages: fix inconsistencies
As part of work done in #14046, fix bugs found in man pages,
basically just moving a few descriptions to the right place
and removing some undesired asterisks.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-05-11 13:14:08 -06:00
22b421dd7e Add CreatedSince & CreatedAt format fields to podman image history
Fixes: https://github.com/containers/podman/issues/14012

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-04-27 15:15:03 -04:00
9b0c8d23bd man pages: sort flags, and keep them that way
Command flags (OPTIONS) in man pages have to date been in
haphazard order. Sometimes that order is sensible, e.g.,
most-important options first, but more often they're
just in arbitrary places. This makes life hard for users.

Here, I update the man-page-check Makefile script so it
checks and enforces alphabetical order in OPTIONS sections.
Then -- the hard part -- update all existing man pages to
conform to this requirement.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-03-23 13:49:42 -06:00
2720156fa5 Add links to all SEE ALSO sections
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-11-10 09:29:21 -05:00
4216f7b7f4 Add no-trunc support to podman-events
Standardize on no-trunc through the code.
Alias notruncate where necessary.

Standardize on the man page display of no-trunc.

Fixes: https://github.com/containers/podman/issues/8941

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-09-16 09:41:29 -04:00
30e731ecc8 Revert escaped double dash man page flag syntax
Commit 800a2e2d35 introduced a way to disable the conversion of `--`into
an en dash on docs.podman.io, so the ugly workaround of escaping the
dashes is no longer necessary.

Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
2021-05-07 18:30:00 +02:00
bc48211924 Fix long option format on docs.podman.io
Escape the two dashes, otherwise they are combined into one long dash.
I tested that this change is safe and still renders correctly on github
and with the man pages.

This commit also contains a small change to make it build locally.
Assuming you have the dependencies installed you can do:
```
cd docs
make html
```
Preview the html files in docs/build/html with
`python -m http.server 8000 --directory build/html`.

Fixes containers/podman.io#373

Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
2021-03-29 14:38:25 +02:00
52a8694705 Add anchors for flag names on docs.podman.io
Change the docs markdown so that flag names will be h4 headers.
Sphinx will automatically add anchors to headers. Add css to
make sure the flag names are not to big compared to the text.

The man pages also still renders fine but it looks a bit different.

Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
2020-11-10 15:27:08 +01:00
35567e706b Attempt to turn on additional build tests
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-05-22 12:55:23 -04:00
4aeb25d5f2 docs: add boolean values and defaults to "man podman-history" options
Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
2020-01-26 14:13:54 -05:00
185373bfeb Fix presentation of man page tables
Currently the use of "*" in tables is causing go-md2man
to screw up the format of the man page.

This PR removes the "*" since it is not really necessary.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-01-03 10:12:14 -05:00
486fcd4e1e Update document formatting and packaging code
* Refactored code and Makefile to support new docs layout
* Removed some old code packaging code
* Add Readme.md to document what we're doing

Signed-off-by: Jhon Honce <jhonce@redhat.com>
Signed-off-by: baude <bbaude@redhat.com>
2019-10-31 12:31:39 -05:00