Skip to content

Commit 5eb0a8f

Browse files
use arithmatex v2 configuration for PDF
1 parent 68465f0 commit 5eb0a8f

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

tools/run-in-container/genpdf.sh

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ function create_target_dir(){
88
function copy_resources() {
99
cp ${DATA_DIR}/mkdocs.yml ${TARGET_DIR}/mkdocs.yml
1010
cp -r ${DATA_DIR}/docs/images ${TARGET_DIR}/docs
11+
cp -r ${DATA_DIR}/docs/javascripts ${TARGET_DIR}/docs/javascripts
1112
cp -r ${DATA_DIR}/docs/stylesheets ${TARGET_DIR}/docs/stylesheets
1213
}
1314

@@ -19,7 +20,12 @@ function copy_resources() {
1920
# with some nice features for the HTML version.
2021
function fix_mkdocs_yml() {
2122
mv ${TARGET_DIR}/mkdocs.yml ${TARGET_DIR}/mkdocs.ori.yml
22-
sed -e 's/linenums_style: table/linenums_style: pymdownx-inline/g' ${TARGET_DIR}/mkdocs.ori.yml > ${TARGET_DIR}/mkdocs.yml
23+
sed -e 's/linenums_style: table/linenums_style: pymdownx-inline/g' ${TARGET_DIR}/mkdocs.ori.yml | \
24+
sed -e 's|javascripts/mathjax.js|https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?config=TeX-MML-AM_CHTML|g' | \
25+
sed -e 's| - https://polyfill.io/v3/polyfill.min.js?features=es6||g' | \
26+
sed -e 's| - https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js||g' | \
27+
sed -e 's/pymdownx.arithmatex:/pymdownx.arithmatex/g' | \
28+
sed -e 's/ generic: true//g' > ${TARGET_DIR}/mkdocs.yml
2329
}
2430

2531
function create_cover() {

0 commit comments

Comments
 (0)