diff options
author | Rob Cowsill <42620235+rcowsill@users.noreply.github.com> | 2021-04-29 21:44:19 +0100 |
---|---|---|
committer | Rob Cowsill <42620235+rcowsill@users.noreply.github.com> | 2021-04-29 22:18:13 +0100 |
commit | b4bbc5210b5676ca76c78dfc14bbae14b201e948 (patch) | |
tree | 12212db588019bffaa70eda4c58a13bf9ab3387a /docs/use-pagetitle.lua | |
parent | 98a84ff34e2f93d50ef4fb41ae127a07bcf5bf42 (diff) | |
download | podman-b4bbc5210b5676ca76c78dfc14bbae14b201e948.tar.gz podman-b4bbc5210b5676ca76c78dfc14bbae14b201e948.tar.bz2 podman-b4bbc5210b5676ca76c78dfc14bbae14b201e948.zip |
[CI:DOCS] Add titles to remote docs (windows)
Previously the podman-remote windows docs had no HTML titles
This gives them the same titles as the equivalent Sphinx HTML pages
Signed-off-by: Rob Cowsill <42620235+rcowsill@users.noreply.github.com>
Diffstat (limited to 'docs/use-pagetitle.lua')
-rw-r--r-- | docs/use-pagetitle.lua | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/docs/use-pagetitle.lua b/docs/use-pagetitle.lua new file mode 100644 index 000000000..ebc92641d --- /dev/null +++ b/docs/use-pagetitle.lua @@ -0,0 +1,14 @@ +local List = require("pandoc.List") + +function Meta(m) + -- Use pagetitle instead of title (prevents pandoc inserting a <H1> title) + m.pagetitle = m.title + m.title = nil + + if m.pagetitle ~= nil and m.pagetitle.t == "MetaInlines" then + -- Add suffix to match the Sphinx HTML documentation + List.extend(m.pagetitle, {pandoc.Str" \u{2014} Podman documentation"}) + end + + return m +end |