Skip to content

Commit 9fe1196

Browse files
committed
CI: Simplify font handling by using Typst font path instead of system installation
1 parent 55ea18b commit 9fe1196

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

.github/workflows/ci.yml

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -182,17 +182,10 @@ jobs:
182182
rm -rf "typst-x86_64-unknown-linux-musl" "typst-x86_64-unknown-linux-musl.tar.xz"
183183
typst --version
184184
185-
- name: Install Fira Sans font
185+
- name: Download Fira Sans font
186186
run: |
187-
# Download and install Fira Sans
188187
wget -q "https://github.com/mozilla/Fira/archive/4.202.zip"
189188
unzip -q "4.202.zip"
190-
sudo mkdir -p /usr/local/share/fonts/fira-sans
191-
sudo cp Fira-4.202/otf/FiraSans-*.otf /usr/local/share/fonts/fira-sans/
192-
sudo fc-cache -f -v
193-
rm -rf "4.202.zip" "Fira-4.202"
194-
# Verify font is available
195-
fc-list | grep -i "fira sans" || echo "Fira Sans not found"
196189
197190
- uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2.8.0
198191
with:
@@ -205,6 +198,10 @@ jobs:
205198

206199
- run: cargo build --tests --workspace
207200
- run: cargo test --workspace
201+
env:
202+
# Set the path to the Fira Sans font for Typst.
203+
# The path is relative to the `crates_io_og_image` crate root.
204+
TYPST_FONT_PATH: ../../Fira-4.202/otf
208205

209206
frontend-lint:
210207
name: Frontend / Lint

0 commit comments

Comments
 (0)