mirror of
https://github.com/containers/podman.git
synced 2025-08-06 11:32:07 +08:00
markdown-preprocess: add generic include mechanism
This is what was supposed to be an easy two-or-three-line change to enable a more general-purpose include mechanism than '@@option'; one that could include an arbitrary file. This is commit 2 of 2, the "easy" part. Unfortunately, it's not looking good. The source .md file has UTF8 checkmarks, and nroff is not happy with those: the generated man pages are gross. Another problem: the source .md might need tweaking, because we don't want a level 1 header in the man page. Obvious solution is to make kubernetes_support.md a .md.in file as well, and move the tables to a separate file (or files). Deferred for later. Signed-off-by: Ed Santiago <santiago@redhat.com>
This commit is contained in:
@ -233,7 +233,7 @@ Pods removed:
|
||||
`podman kube play --down` will not work with a URL if the YAML file the URL points to
|
||||
has been changed or altered.
|
||||
|
||||
@@option tls-verify
|
||||
@@include ../../kubernetes_support.md
|
||||
|
||||
## SEE ALSO
|
||||
**[podman(1)](podman.1.md)**, **[podman-kube(1)](podman-kube.1.md)**, **[podman-kube-down(1)](podman-kube-down.1.md)**, **[podman-network-create(1)](podman-network-create.1.md)**, **[podman-kube-generate(1)](podman-kube-generate.1.md)**, **[containers-certs.d(5)](https://github.com/containers/image/blob/main/docs/containers-certs.d.5.md)**
|
||||
|
@ -43,6 +43,10 @@ class Preprocessor():
|
||||
_, optionname = line.strip().split(" ")
|
||||
optionfile = os.path.join("options", optionname + '.md')
|
||||
self.insert_file(fh_out, optionfile)
|
||||
# '@@include relative-path/must-exist.md'
|
||||
elif line.startswith('@@include '):
|
||||
_, path = line.strip().split(" ")
|
||||
self.insert_file(fh_out, path)
|
||||
else:
|
||||
fh_out.write(line)
|
||||
|
||||
|
Reference in New Issue
Block a user