1
0
mirror of https://github.com/ryanoasis/nerd-fonts.git synced 2024-12-13 17:18:37 +02:00
nerd-fonts/bin/scripts
Fini Jastrow 3c4fa008c1 gotta-patch-em-all: Add options to simplify patcher testing
[why]
When working on the font-patcher the developer needs to test the changes
on a number of fonts. This is usually a manual call of `font-patcher`
and afterwards a 'diff' of the newly created font with the 'old' font in
the patched-fonts/ directory with fontforge (which has a font-compare
option).

If you run gotta-patch-em-all normally the newly generated font will
replace the existing font and git will ALWAYS show it as different. The
reason is that at least the timestamp in the generated font has changed.
Far more easy would be if the new gotta-patch-em-all run could keep the
previous timestamps, in that way one can immediately see that the old
and new fonts are bitwise equal (via git).

Furthermore if you expect a change and want to show the differences of
old and new font in fontforge you need both fonts in the filesystem.
But a normal gotta-patch-em-all run replaces the font. A different
destination folder would help here.

[how]
Introduce two new (independent) options to
a) keep the timestamp equal to previous patch run
b) generate the fonts in a different directory

While b) is straight forward, a) is a bit more complicated, esp because
filenames can change and so on. So the script examines just one (1)
random font in the specific font directory and uses its timestamp. In
most cases this is correct enough if the developer uses gotta-patch-em-all
consequently.

Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
2023-01-06 08:32:48 +01:00
..
data Rename 'Font Linux' to 'Font Logos' 2022-09-13 08:05:14 +02:00
Hack [ci] Bump release version 2022-10-07 11:55:35 +00:00
lib generate-font-image-previews: Generate Symbols Only preview 2022-12-19 21:09:29 +01:00
name_parser font-patcher: Prevent --mono on proportional fonts 2022-09-24 16:56:30 +02:00
archive-font-patcher.sh [ci] Bump release version 2022-10-07 11:55:35 +00:00
archive-fonts.sh archive-fonts: Fix missing licence files 2022-10-24 13:55:45 +02:00
docker-entrypoint.sh Merge branch 'master' into docker 2021-11-26 18:13:11 -08:00
fetch-archives.sh fetch-archives: Decouple from patched-fonts dir 2022-12-14 09:45:59 +01:00
fpfix.py add combined prefix to fpfix.py 2017-05-19 03:11:58 -05:00
generate-casks.sh casks: Fix cask generation for 'deep' archives [skip ci] 2022-12-14 18:49:32 +01:00
generate-css.sh [ci] Bump release version 2022-10-07 11:55:35 +00:00
generate-font-image-previews.sh generate-font-image-previews: Fit svg canvas to drawing [skip ci] 2022-12-19 21:19:29 +01:00
generate-fontconfig.sh [ci] Bump release version 2022-10-07 11:55:35 +00:00
generate-glyph-info-from-set.py Remove mentions of master branch [skip ci] 2022-10-17 11:50:53 +02:00
generate-original-source.py [ci] Bump release version 2022-10-07 11:55:35 +00:00
generate-webfonts.sh CI: Fix: Automatically deploy webfonts [skip ci] 2022-12-16 19:08:53 +01:00
get-font-names-from-json.sh [ci] Bump release version 2022-10-07 11:55:35 +00:00
gotta-patch-em-all-font-patcher!.sh gotta-patch-em-all: Add options to simplify patcher testing 2023-01-06 08:32:48 +01:00
optimize-original-source.sh [ci] Bump release version 2022-10-07 11:55:35 +00:00
README.md CI: Automatically deploy webfonts [skip ci] 2022-12-16 17:14:30 +01:00
release.sh [ci] Bump release version 2022-10-07 11:55:35 +00:00
standardize-and-complete-readmes.sh [ci] Bump release version 2022-10-07 11:55:35 +00:00
test-fonts.sh [ci] Bump release version 2022-10-07 11:55:35 +00:00
test-powerlines.sh [ci] Bump release version 2022-10-07 11:55:35 +00:00
tests.sh [ci] Bump release version 2022-10-07 11:55:35 +00:00
update-all-contributors-website.py Adds a very basic script to update all contributors section on the website 2020-04-06 01:02:15 -07:00
version-bump.sh [ci] Bump release version 2022-10-07 11:55:35 +00:00

Contents

Note: Usually you need to call the scripts in this directory while actually being in this directory (i.e. pwd = .../nerd-fonts/bin/scripts).

  • archive-font-patcher.sh: Archives the font patcher script and subscripts and the required source glyph files [1]
  • archive-fonts.sh: Creates the release zip file of one or more font(s) from existing patched-fonts/ content [1]
  • data/: Contains plain text files used to generate the CSS and cheat sheet files
  • data/sankey/: Contains instructions on how to create the sankey glyph table manually [3]
  • docker-entrypoint.sh: This script is packaged into the docker container and is usually used to start patching [2]
  • fetch-archives.sh: Script to download the release zip archives [6]
  • fpfix.py: Can be used to set isFixedPitch property in a font [x]
  • generate-casks.sh: Generates cask files for fonts from data in archives/ [6]
  • generate-css.sh: Generates the Nerd Fonts CCS, which can be used to access the glyphs on a web page [1]
  • generate-fontconfig.sh: Generates font configuration to enable use of unpatched fonts with Symbols Only Nerd Font [1]
  • generate-font-image-previews.sh: Generates the preview images for nerdfonts.com (i.e. gh-pages) [3]
  • generate-glyph-info-from-set.py: Generate the i_xxx.sh file from a glyph source (font) file, if the glyphs are named correctly [4]
  • generate-original-source.py: Generate original-source.otf from single glyph svgs. [5]
  • generate-webfonts.sh: Generate woff and woff2 font files from the SymbolsOnly font (for the gh-pages) [1]
  • get-font-names-from-json.sh: Helper to setup the CI font matrix from data/fonts.json [1]
  • gotta-patch-em-all-font-patcher!.sh: Patch one or more fonts 'complete' with and without mono and with and without windows compat [1]
  • Hack/: Special additional post patching script for Hack, invoked via Hack's config.cfg (not used when self-patching)
  • lib/: See its own README
  • name_parser/: Suite to set up sane Family and SubFamily names, used by font-patcher (on demand)
  • optimize-original-source.sh: Run all icons in src/svgs through inkscape to simplify (remove nodes and edges) [5]
  • release.sh: Rough process how a release is created, not used (see .github/workflows/release.yml)
  • standardize-and-complete-readmes.sh [1]
  • test-fonts.sh: Print-to-debug all glyphs we patch in [4]
  • test-powerlines.sh: Print-to-debug powerline examples [4]
  • tests.sh: Create some font usage gif movie? [x]
  • update-all-contributors-website.py: Update the contributors page on nerdfonts.com (i.e. gh-pages) (Hardcoded paths!) [3]
  • version-bump.sh: Change version number in all scripts on a new release [1]

[1] Used by CI (github release workflow) [2] Used by CI (github docker-release workflow) [3] To be used manually (sigh) [4] To be used manually [5] Used by CI (github packsvgs workflow) [6] Used by CI (github casks workflow) [x] Probably not used by anything