Skip to content

Commit a7861dc

Browse files
committed
CI: Simplify font handling by using Typst font path instead of system installation
1 parent 266fae4 commit a7861dc

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
@@ -177,17 +177,10 @@ jobs:
177177
rm -rf "typst-x86_64-unknown-linux-musl" "typst-x86_64-unknown-linux-musl.tar.xz"
178178
typst --version
179179
180-
- name: Install Fira Sans font
180+
- name: Download Fira Sans font
181181
run: |
182-
# Download and install Fira Sans
183182
wget -q "https://github.com/mozilla/Fira/archive/4.202.zip"
184183
unzip -q "4.202.zip"
185-
sudo mkdir -p /usr/local/share/fonts/fira-sans
186-
sudo cp Fira-4.202/otf/FiraSans-*.otf /usr/local/share/fonts/fira-sans/
187-
sudo fc-cache -f -v
188-
rm -rf "4.202.zip" "Fira-4.202"
189-
# Verify font is available
190-
fc-list | grep -i "fira sans" || echo "Fira Sans not found"
191184
192185
- uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2.8.0
193186
with:
@@ -200,6 +193,10 @@ jobs:
200193

201194
- run: cargo build --tests --workspace
202195
- run: cargo test --workspace
196+
env:
197+
# Set the path to the Fira Sans font for Typst.
198+
# The path is relative to the `crates_io_og_image` crate root.
199+
TYPST_FONT_PATH: ../../Fira-4.202/otf
203200

204201
frontend-lint:
205202
name: Frontend / Lint

0 commit comments

Comments
 (0)