1
0
mirror of https://github.com/google/comprehensive-rust.git synced 2025-04-26 09:12:58 +02:00

Fix missing images and Arabic fonts in course PDFs (#2544)

Let's give #2531 another try
- Fixes missing images in PDFs (those specified as <img> elements)
- Configures Arabic fonts

[The
fix](https://github.com/max-heller/mdbook-pandoc/pull/144/files#diff-b17b0f99aa22ee1ccf99778ca74c3c7a27af87f41544194cc95f82c012e8a507)
for the Persian translation issue, if you're curious.
This commit is contained in:
Max Heller 2025-01-14 11:23:30 -05:00 committed by GitHub
parent 0c91136396
commit 9493a8deb7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 12 additions and 5 deletions

View File

@ -17,11 +17,11 @@ runs:
- name: Install mdbook-pandoc and related dependencies
run: |
cargo install mdbook-pandoc --locked --version 0.7.0
cargo install mdbook-pandoc --locked --version 0.9.0
sudo apt-get update
sudo apt-get install -y texlive texlive-luatex texlive-lang-cjk librsvg2-bin fonts-noto
curl -LsSf https://github.com/jgm/pandoc/releases/download/3.2.1/pandoc-3.2.1-linux-amd64.tar.gz | tar zxf -
echo "$PWD/pandoc-3.2.1/bin" >> $GITHUB_PATH
sudo apt-get install -y texlive texlive-luatex texlive-lang-cjk texlive-lang-arabic librsvg2-bin fonts-noto
curl -LsSf https://github.com/jgm/pandoc/releases/download/3.6.2/pandoc-3.6.2-linux-amd64.tar.gz | tar zxf -
echo "$PWD/pandoc-3.6.2/bin" >> $GITHUB_PATH
shell: bash
- name: Install mdbook-i18n-helpers

View File

@ -40,11 +40,18 @@ pdf-engine = "lualatex"
mainfont = "Noto Serif"
sansfont = "Noto Sans"
monofont = "Noto Sans Mono"
mainfontfallback = ["NotoColorEmoji:mode=harf"]
mainfontfallback = [
"NotoColorEmoji:mode=harf",
"NotoNaskhArabic:",
]
sansfontfallback = [
"NotoSansArabic:",
]
monofontfallback = [
"NotoColorEmoji:mode=harf",
"NotoSansMath:",
"NotoSansMonoCJKSC:",
"NotoSansArabic:",
]
geometry = ["margin=1.25in"]
linkcolor = "blue"