I want to write an asciidoc document which includes mathematical expressions.
I use STEM blocks to write using latex syntax:
File: index.adoc:
= Hello World
:stem: latexmath
Inline math stem:[\alpha + \beta] followed by a block equation:
[stem]
++++
\alpha + \beta = \gamma
++++
Now I want to generate HTML output and later publish it to confluence.
When generating HTML, asciidoctor will generate code with the default mathjax deliiters, \[, \], \(, \).
However our Confluence MathJax plugin does not support the delimiters above. Thus, I followed this tutorial to write a custom converter that changes the delimiters.
Edited: I tested my custom converter with inline stem, which did not work in the original implentation. Thus, I did not see any result and thought the converter was not called at all.
Some Background and description
I want to write an asciidoc document which includes mathematical expressions.
I use STEM blocks to write using latex syntax:
File:
index.adoc
:Now I want to generate HTML output and later publish it to confluence. When generating HTML, asciidoctor will generate code with the default mathjax deliiters,
\[
,\]
,\(
,\)
.However our Confluence MathJax plugin does not support the delimiters above. Thus, I followed this tutorial to write a custom converter that changes the delimiters.
File:
my-html5-converter.rb
I can now generate the HTML site using asciidoctor with:
Delimiters are changed and everything renders correctly.
Actual ProblemSolutionThe actual question is: How to a run the above example using
asciidoctor-gradle-plugin
?The following
build.gradle
works:Edited: I tested my custom converter with inline stem, which did not work in the original implentation. Thus, I did not see any result and thought the converter was not called at all.
The problem was the user, not the plugin.