Skip to content

Commit 4c00d42

Browse files
committed
ci: install HarmonyOS Sans
1 parent 369d557 commit 4c00d42

File tree

2 files changed

+26
-12
lines changed

2 files changed

+26
-12
lines changed

.github/workflows/pages.yml

Lines changed: 25 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: Deploy to GitHub Pages
22

33
on:
44
# Trigger the workflow every time you push to the `main` branch
5-
# Using a different branch name? Replace `main` with your branchs name
5+
# Using a different branch name? Replace `main` with your branch's name
66
push:
77
branches: [src]
88
# Allows you to run this workflow manually from the Actions tab on GitHub.
@@ -20,18 +20,32 @@ jobs:
2020
steps:
2121
- name: Checkout your repository using git
2222
uses: actions/checkout@v4
23-
- name: Enable Universe repository # for lmodern fonts
24-
run: sudo add-apt-repository universe -y
25-
- name: Install Noto fonts and Latin Modern Sans
26-
run: sudo apt-get install -y fonts-noto-cjk-extra fonts-lmodern
27-
- name: Install IBM Plex Sans SC font
23+
- name: Install all fonts (concurrent)
2824
run: |
29-
curl -L https://github.com/IBM/plex/releases/download/%40ibm%2Fplex-sans-sc%401.1.0/ibm-plex-sans-sc.zip -o ibm-plex-sans-sc.zip
30-
unzip ibm-plex-sans-sc.zip -d ./fonts
31-
sudo mkdir -p /usr/share/fonts/truetype/ibm-plex
32-
find ./fonts/ibm-plex-sans-sc/fonts/complete/ttf -name "*.ttf" -exec sudo cp {} /usr/share/fonts/truetype/ibm-plex/ \;
25+
sudo add-apt-repository universe -y
26+
sudo apt-get update
27+
28+
# APT 装系统包
29+
sudo apt-get install -y fonts-noto-cjk-extra fonts-lmodern &
30+
31+
# IBM Plex
32+
(
33+
curl -L https://github.com/IBM/plex/releases/download/%40ibm%2Fplex-sans-sc%401.1.0/ibm-plex-sans-sc.zip -o ibm-plex-sans-sc.zip
34+
unzip -q ibm-plex-sans-sc.zip -d ./fonts
35+
sudo mkdir -p /usr/share/fonts/truetype/ibm-plex
36+
find ./fonts/ibm-plex-sans-sc/fonts/complete/ttf -name "*.ttf" -exec sudo cp {} /usr/share/fonts/truetype/ibm-plex/ \;
37+
) &
38+
39+
# HarmonyOS Sans
40+
(
41+
git clone --depth=1 https://gitee.com/openharmony/utils_system_resources.git
42+
cd utils_system_resources/fonts
43+
sudo mkdir -p /usr/share/fonts/truetype/harmonyos
44+
find . -name "*.ttf" -exec sudo cp {} /usr/share/fonts/truetype/harmonyos/ \;
45+
) &
46+
47+
wait # 等三条后台任务全部结束
3348
sudo fc-cache -f -v
34-
fc-list | grep -i "IBM Plex"
3549
- name: Install, build, and upload my site
3650
uses: withastro/action@v4
3751
with:

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "neko-astro-blog",
33
"type": "module",
4-
"version": "2.21.4",
4+
"version": "2.21.6",
55
"private": true,
66
"engines": {
77
"node": ">=20"

0 commit comments

Comments
 (0)