From b4bbc5210b5676ca76c78dfc14bbae14b201e948 Mon Sep 17 00:00:00 2001 From: Rob Cowsill <42620235+rcowsill@users.noreply.github.com> Date: Thu, 29 Apr 2021 21:44:19 +0100 Subject: [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> --- docs/use-pagetitle.lua | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 docs/use-pagetitle.lua (limited to 'docs/use-pagetitle.lua') 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

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 -- cgit v1.2.3-54-g00ecf