From 9f3b7f1171b540e06beae70757a66decbcc66cf3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Fran=C3=A7ois=20Grand?= <francois.grand@inrae.fr>
Date: Wed, 30 Nov 2022 17:49:33 +0100
Subject: [PATCH] fix(doc): missing links to image in PDF generation
refs #578
---
mkdocs2pdf.py | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/mkdocs2pdf.py b/mkdocs2pdf.py
index 465aeef43..9109fe9e2 100644
--- a/mkdocs2pdf.py
+++ b/mkdocs2pdf.py
@@ -156,6 +156,18 @@ def injectContentIntoModel(mergedDocFilenameTex, lang):
runCommand(
'ln -s ../../latex/logo_pole.png .'
)
+ runCommand(
+ 'ln -s {}/schema_rugosite_fond.png'.format(os.path.join(baseDir, 'docs', lang, 'calculators', 'pam'))
+ )
+ runCommand(
+ 'ln -s {}/bloc_cylindre.png'.format(os.path.join(baseDir, 'docs', lang, 'calculators', 'pam'))
+ )
+ runCommand(
+ 'ln -s {}/bloc_face_arrondie.png'.format(os.path.join(baseDir, 'docs', lang, 'calculators', 'pam'))
+ )
+ runCommand(
+ 'ln -s {}/bloc_base_carree.png'.format(os.path.join(baseDir, 'docs', lang, 'calculators', 'pam'))
+ )
runCommand(
'rm rapport_inrae/logos.tex'
)
@@ -176,7 +188,7 @@ def buildPDF(lang):
cvt = os.path.join( baseDir,'docs/cassiopee_version.tex')
shutil.copy(cvt, modelDir)
- runCommand(
+ os.system(
'latexmk -f -xelatex -pdf -interaction=nonstopmode {} > /dev/null 2>&1'.format(sourceTexFile)
)
# copy generated PDF to release directory
--
GitLab