From 387c92333e846ab3ebe894453d23ff72d44d310c Mon Sep 17 00:00:00 2001 From: Paul Tsouchlos Date: Thu, 19 Sep 2024 12:46:27 -0600 Subject: [PATCH] ci: ensure tests have all fonts properly installed --- .github/workflows/tests.yml | 3 ++- scripts/install-source-sans | 11 +++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100755 scripts/install-source-sans diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index e9a6d88..fbde800 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -52,8 +52,9 @@ jobs: - name: Install fonts run: | sudo apt update - sudo apt-get install fonts-font-awesome fonts-roboto + sudo apt-get install fonts-roboto ./scripts/install-fontawesome + ./scripts/install-source-sans - name: Install locally run: just install diff --git a/scripts/install-source-sans b/scripts/install-source-sans new file mode 100755 index 0000000..cde6371 --- /dev/null +++ b/scripts/install-source-sans @@ -0,0 +1,11 @@ +#!/usr/bin/env bash +set -eu + +wget -O ~/source-sans.zip https://github.com/adobe-fonts/source-sans/releases/download/3.052R/OTF-source-sans-3.052R.zip +mkdir -p ~/source-sans-fonts +unzip ~/source-sans.zip -d ~/source-sans-fonts +mkdir -p ~/.fonts +find ~/source-sans-fonts -type f -name "*.otf" -exec cp {} ~/.fonts \; +rm ~/source-sans.zip +rm -rf ~/source-sans-fonts +fc-cache -f -v