File tree Expand file tree Collapse file tree 2 files changed +20
-2
lines changed
doc/doxygen-root/doxygen-markdown Expand file tree Collapse file tree 2 files changed +20
-2
lines changed Original file line number Diff line number Diff line change @@ -10,11 +10,14 @@ jobs:
1010 uses : actions/checkout@v3
1111
1212 - name : Install doxygen
13- run : sudo apt install doxygen graphviz pandoc
13+ run : sudo apt install doxygen graphviz pandoc npm
1414
1515 - name : Install python modules
1616 run : sudo python3 -m pip install gitpython pandocfilters
1717
18+ - name : Install mermaid diagram filter
19+ run : sudo npm install --global mermaid-filter
20+
1821 - name : Build documentation
1922 run : cd doc/doxygen-root && make && touch html/.nojekyll
2023
Original file line number Diff line number Diff line change @@ -34,6 +34,21 @@ $BINDIR/append-last-modified-dates.py $FILES
3434# $BINDIR/pandoc-codeblock-repair.sh > $file
3535# done
3636
37+ echo
38+ echo " Rendering mermaid diagrams"
39+ FILES=$( grep --include=\* .md -rl . -e " \`\`\` mermaid" )
40+ for file in $FILES ; do
41+ echo $file
42+ tmp=/tmp/${file% .* } 2.md
43+ mkdir -p $( dirname $tmp )
44+ cp $file $tmp
45+ # Note that gfm is GitHub Flavour Markdown. The double \\ at the start of
46+ # lines is unescaped using sed in order to fix doxygen tags, which are
47+ # broken by pandoc.
48+ pandoc --read=gfm --write=gfm --wrap=none --filter=mermaid-filter $tmp |
49+ $BINDIR /pandoc-codeblock-repair.sh | sed ' s/^\\\\/\\/' > $file
50+ done
51+
3752cprovers=$( find . -name cprover-manual)
3853cprover=${cprovers[0]}
3954
@@ -49,7 +64,7 @@ echo "Running pandoc filter over cprover-manual markdown files"
4964FILES=$( find $cprover -name ' *.md' )
5065for file in $FILES ; do
5166 echo $file
52- tmp=/tmp/${file% .* } 2 .md
67+ tmp=/tmp/${file% .* } 3 .md
5368 mkdir -p $( dirname $tmp )
5469 cp $file $tmp
5570 pandoc --write=markdown_phpextra --wrap=none --filter=$BINDIR /pandoc-cprover-link-filter.py $tmp |
You can’t perform that action at this time.
0 commit comments