Skip to content

Commit 304c549

Browse files
committed
ci: install fonts for jekyll-og-image generation
Add Plus Jakarta Sans and Inter fonts to the docs workflow to ensure proper rendering of Open Graph images with the configured typography
1 parent c80b1e3 commit 304c549

19 files changed

+24
-1
lines changed

.github/workflows/docs.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,25 @@ jobs:
3939
sudo apt-get update -qq
4040
sudo apt-get install -y --no-install-recommends libvips-dev
4141
42+
- name: Install fonts for OG image generation
43+
run: |
44+
# Install Inter font from apt
45+
sudo apt-get install -y fonts-inter fonts-inter-variable
46+
47+
# Download and install Plus Jakarta Sans from Google Fonts
48+
wget -O Plus_Jakarta_Sans.zip "https://fonts.google.com/download?family=Plus%20Jakarta%20Sans"
49+
sudo mkdir -p /usr/share/fonts/truetype/plus-jakarta-sans
50+
sudo unzip -d /usr/share/fonts/truetype/plus-jakarta-sans/ Plus_Jakarta_Sans.zip
51+
rm Plus_Jakarta_Sans.zip
52+
53+
# Update font cache
54+
sudo fc-cache -fv
55+
56+
# Verify fonts are installed
57+
echo "Installed fonts:"
58+
fc-list | grep -i inter || echo "Inter font not found"
59+
fc-list | grep -i jakarta || echo "Plus Jakarta Sans not found"
60+
4261
- name: Setup Ruby for Jekyll build (ruby_llm environment)
4362
uses: ruby/setup-ruby@v1
4463
with:

docs/_config.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,9 @@ og_image:
8080
domain: "rubyllm.com"
8181
header:
8282
prefix: "RubyLLM Docs: "
83+
font_family: "Plus Jakarta Sans, bold"
84+
content:
85+
font_family: "Inter, regular"
8386
metadata:
8487
fields:
8588
- description
963 Bytes
Loading
818 Bytes
Loading
345 Bytes
Loading
1.84 KB
Loading
516 Bytes
Loading
-84 Bytes
Loading
937 Bytes
Loading
-133 Bytes
Loading

0 commit comments

Comments
 (0)