Skip to content

Commit

Permalink
try to fix markdown blocks
Browse files Browse the repository at this point in the history
  • Loading branch information
ljblancoredborder committed Oct 8, 2024
1 parent ea292bd commit 7846882
Showing 1 changed file with 25 additions and 1 deletion.
26 changes: 25 additions & 1 deletion .github/workflows/create-pdf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,18 @@ jobs:
- name: Convert MD to PDF (English)
run: |
pandoc -o documentation_en.pdf --pdf-engine=xelatex \
--from markdown+yaml_metadata_block+raw_html \
--lua-filter=<(echo '
function Block (elem)
if elem.t == "Div" and elem.classes[1] == "info" then
return {
pandoc.RawBlock("latex", "\\begin{tcolorbox}[colback=blue!5!white,colframe=blue!75!black,title=Info]"),
elem,
pandoc.RawBlock("latex", "\\end{tcolorbox}")
}
end
end
') \
docs/index.md \
$(find docs/manager/redborder_basics -name '*.md' ! -name '*.es.md') \
$(find docs/manager/more_in_detail -name '*.md' ! -name '*.es.md') \
Expand All @@ -33,7 +45,19 @@ jobs:
- name: Convert MD to PDF (Spanish)
run: |
find docs -name "*.es.md" -type f -print0 | xargs -0 pandoc -o documentation_es.pdf --pdf-engine=xelatex
find docs -name "*.es.md" -type f -print0 | xargs -0 pandoc -o documentation_es.pdf --pdf-engine=xelatex \
--from markdown+yaml_metadata_block+raw_html \
--lua-filter=<(echo '
function Block (elem)
if elem.t == "Div" and elem.classes[1] == "info" then
return {
pandoc.RawBlock("latex", "\\begin{tcolorbox}[colback=blue!5!white,colframe=blue!75!black,title=Info]"),
elem,
pandoc.RawBlock("latex", "\\end{tcolorbox}")
}
end
end
')
- name: Upload PDF artifacts
uses: actions/upload-artifact@v4
Expand Down

0 comments on commit 7846882

Please sign in to comment.