From ca52a0485e23da55bd0c15299a52303c6de439bb Mon Sep 17 00:00:00 2001 From: David Steele Date: Fri, 16 Feb 2018 14:46:02 -0500 Subject: [PATCH] Allow code blocks to have a type. Currently this is only rendered in Markdown. --- doc/lib/BackRestDoc/Markdown/DocMarkdownRender.pm | 9 ++++++++- doc/xml/dtd/doc.dtd | 1 + doc/xml/release.xml | 4 ++++ 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/doc/lib/BackRestDoc/Markdown/DocMarkdownRender.pm b/doc/lib/BackRestDoc/Markdown/DocMarkdownRender.pm index a0d92d60d..8e817d929 100644 --- a/doc/lib/BackRestDoc/Markdown/DocMarkdownRender.pm +++ b/doc/lib/BackRestDoc/Markdown/DocMarkdownRender.pm @@ -290,7 +290,14 @@ sub sectionProcess $strMarkdown .= "\n_" . $oChild->paramGet('title') . "_:"; } - $strMarkdown .= "\n```\n" . trim($oChild->valueGet()) . "\n```"; + $strMarkdown .= "\n```"; + + if ($oChild->paramTest('type')) + { + $strMarkdown .= $oChild->paramGet('type'); + } + + $strMarkdown .= "\n" . trim($oChild->valueGet()) . "\n```"; } # Add descriptive text elsif ($oChild->nameGet() eq 'p') diff --git a/doc/xml/dtd/doc.dtd b/doc/xml/dtd/doc.dtd index 49ac31d13..78a2da09a 100644 --- a/doc/xml/dtd/doc.dtd +++ b/doc/xml/dtd/doc.dtd @@ -226,6 +226,7 @@ + diff --git a/doc/xml/release.xml b/doc/xml/release.xml index 7dcc56351..f6d61d73d 100644 --- a/doc/xml/release.xml +++ b/doc/xml/release.xml @@ -149,6 +149,10 @@

Improve section source feature to not require a title or content. The title will be pulled from the source document.

+ +

Allow code blocks to have a type. Currently this is only rendered in Markdown.

+
+

Deploy historical documentation to prior rather than the root directory.