1
0
mirror of https://github.com/ryanoasis/nerd-fonts.git synced 2025-01-06 21:49:40 +02:00

CI: Regenerate glyphnames before release

[why]
When the icon sets have changed (added or names changed) the i_*.sh
files are (hopefully) up to date, but the glyphnames.json file is only
updated on release.

Unfortunately the font-patcher uses the glyphnames.json to determine the
patched-in glyphs' names, but in the workflow the json file is only
updated after all fonts have been patched.

[how]
Like the version number in the font-patcher file we also create a
transient glyphnames.json in each patching job, that the font-patcher
can then utilize.

Still the in-repo glyphnames.json is only updated after successful
release. So in pinciple we call the generate-css.sh (which also
generates the glyphnames.json) once for every font in the font matrix
(just before patching) and then finally after all patching has been done
again and that is committed back to the repo.

Fixes: #1745

Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
This commit is contained in:
Fini Jastrow 2024-11-26 14:12:15 +01:00 committed by Fini
parent b4d1b5bdd1
commit 7b23967286

View File

@ -198,10 +198,13 @@ jobs:
fontforge --version
fontforge --version 2>&1 | grep libfontforge | awk '{print $NF}'
- name: Bump version for source files
- name: Bump version for source files and update glyphnames.json
# and check if generated glyphnames.json is valid
run: |
cd -- "$GITHUB_WORKSPACE/bin/scripts"
./version-bump.sh "$RELEASE_VERSION"
./generate-css.sh
jq . ../../glyphnames.json > /dev/null
- name: Patch all the variations of the font family
run: |