10 Commits

Author SHA1 Message Date
Sebastiaan van Stijn
535bb6c85c
rewrite using "with-go-mod.sh" script and "go run"
Use the same script as is used in moby/moby, which more gracefully
handles an existing `go.mod` (which can be symlinked) into account.

- keep the scripts called generic, and update the Makefile to invoke
  them with the "with-go-mod.sh" script.
- use "go run" instead of building temporary binaries
- check if go-md2man exists before building a binary

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-03-21 00:36:47 +01:00
Aleksa Sarai
47775a8fa0
docs: include required tools in source tree
In order to be able to build the documentation without internet access
(as is required by some distribution build systems), all of the source
code needed for the build needs to be available in the source tarball.

This used to be possible with the docker-cli sources but was
accidentally broken with some CI changes that switched to downloading
the tools (by modifying go.mod as part of the docs build script).

This pattern also maked documentation builds less reproducible since the
tool version used was not based on the source code version.

Fixes: 7dc35c03fca5 ("validate manpages target")
Fixes: a650f4ddd008 ("switch to cli-docs-tool for yaml docs generation")
Signed-off-by: Aleksa Sarai <cyphar@cyphar.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-03-21 00:13:56 +01:00
Sebastiaan van Stijn
7244f7d42f
update cli-docs-tool to v0.9.0
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-01-13 18:59:22 +01:00
Sebastiaan van Stijn
64a3fb82dc
docs: fix typos and version for cli-docs-tool scripts
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2024-07-17 15:25:37 +02:00
David Karlsson
8549d250f6 docs: update cli-docs-tool (v0.8.0)
Signed-off-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
2024-07-04 10:28:53 +02:00
Sebastiaan van Stijn
f2e98f9a93
docs: regenerate markdown
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2024-02-21 10:40:13 +01:00
David Karlsson
d633890f91 docs: move base command to docker.md
CLI reference for the base command was generated to cli.md

Changed it to docker.md to handle broken links.

Signed-off-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
2024-01-19 14:44:35 +01:00
Sebastiaan van Stijn
17f4c8259b
update cli-docs-tool to v0.6.0
release notes: https://github.com/docker/cli-docs-tool/releases/tag/v0.6.0

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-08-28 01:58:58 +02:00
Sebastiaan van Stijn
37f234fbe7
scripts/docs/generate-md.sh: fix location of generate code
Commit 1e3622c50cc80bb578c59dc242630ee815e678fd moved the generator code
to a subdirectory, but forgot to update the markdown version of this script.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-04-09 13:35:55 +02:00
Kevin Alvarez
79c9e527a3
docs: generate markdown
Keep frontmatter for docker, dockerd and index markdown files.
Also needs to move cli.md > docker.md before generation and
then move it back because cli.md is needed for yaml generation on docs
website: https://github.com/docker/cli/pull/3924#discussion_r1059986605

Signed-off-by: Kevin Alvarez <crazy-max@users.noreply.github.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-01-06 22:36:47 +01:00