Skip to content
Snippets Groups Projects
Commit 1cdd9664 authored by Dorch's avatar Dorch
Browse files

docs(pdf): handle multiline internal links

Refs #656
parent f1b843ed
No related branches found
No related tags found
2 merge requests!252release: version 4.18.0,!251Resolve "Documentation PDF: erreurs à la compilation"
......@@ -222,7 +222,7 @@ def buildDocForLang(lang):
mergedDocFilename = mergedDocFilenamePrefix + lang
mergedDocOutputPath = os.path.join(pdfBuildDir, mergedDocFilename)
# remove internal links @TODO convert them to hyperref ?
s = re.sub(r'\[([^/\^]+?)\]\([^ ]+?\.md\)', r'\1', s)
s = re.sub(r'\[([^/\^]+?)\]\([^ ]+?\.md\)', r'\1', s, flags=re.MULTILINE)
with open('{}.md'.format(mergedDocOutputPath), 'w') as f:
f.writelines(s)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment