Skip to content
This repository has been archived by the owner on May 16, 2024. It is now read-only.

Update Nerd Font casks to v2.2.2 #6758

Merged
merged 1 commit into from
Dec 14, 2022
Merged

Conversation

Finii
Copy link
Contributor

@Finii Finii commented Dec 14, 2022

Important: Do not tick a checkbox if you haven’t performed its action. Honesty is indispensable for a smooth review process.

In the following questions <cask> is the token of the cask you're submitting.

After making all changes to a cask, verify:

Additionally, if adding a new cask:

(2 new Casks, 49 Casks just updated)

  • Named the cask according to the token reference.
  • Checked the cask was not already refused.
  • Checked the cask is submitted to the correct repo.
  • brew audit --new-cask <cask> worked successfully.
  • brew install --cask <cask> worked successfully.
  • brew uninstall --cask <cask> worked successfully.

Note

These are the automatically generated Casks for all Nerd Fonts for Release v2.2.2.
The casks are can now be generated by the Nerd Font release workflow and will keep the Casks up to date always.

  • The format of the Cask files follows the example of the existing ones.
  • Naming has been fixed for some Casks (Cask-filename is unchanged)
  • The fonts within one Cask are now sorted, to keep diffs small (but they are bigger this time)
  • Two new fonts seems to be added (Aurulent and Lilex)
  • Some fonts are available as ttf and otf, and both are included - I'm not sure that this is smart (but I kept it that way)
  • Some Casks are touched although there is no update - the Casks are just brought in line with the automated ones. We could in principle remove these from the PR and change the Casks only after the next release. Let me know if you prefer that.

Related discussions

Further note

I wanted to set the workflows up to create a Draft Pull Request automatically and a Nerd Font maintainer can then 'push it off' by setting it ready, but it seems all your CI already runs also on drafts, so I do not do that anymore. Maybe worth considering. And maybe I'm wrong and the draft state is somehow observed.

@Finii
Copy link
Contributor Author

Finii commented Dec 14, 2022

Addressing syntax problem, sorry...

image

@Finii
Copy link
Contributor Author

Finii commented Dec 14, 2022

The Gohu release zip has a general problem. Excluded it from this PR. (It uses some legacy paths inside.)
Will fix our workflow.

Copy link
Member

@p-linnane p-linnane left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @Finii!

@p-linnane p-linnane merged commit fbc1e84 into Homebrew:master Dec 14, 2022
Finii added a commit to ryanoasis/nerd-fonts that referenced this pull request Dec 14, 2022
[why]
Normally the release zip files have a flat directory structure, i.e. all
files are in the base directory and there are no subdirs. The existing
subdirectory structure is removed on zip creation via `archive-fonts.sh`.

If the patch results have two fonts with identical name these flat
archives can not be generated. The `archive-fonts.sh` reports:

    Could not create archive with the path junked (-j option) - likely
    same font names for different paths, zip status: $zipStatus
    Retrying with full path

But now the problem is only delayed. When the font file has the name
name the Family and SubFamily are most likely also the same for both
font files. If we install both the user (and the system) can not really
distinguish the font files anymore.

This turned up with [1] when doing a `brew style *nerd-font*` that
complains in fact about duplicate fonts to install. At that point we had
the additional problem that the subdir-path had been missing in the cask
files. So I'm not sure if it would work from a Cask standpoint (i.e.
font files are installed in subdirs).

Anyhow, this will fail when the user wants to select the font files,
because normally this is done on a Family-name basis. And identical file
name usually means identical Family-SubFamily.

Note that this ONLY happens with GohuFont, which has these subdirs:

    11/complete
    14/complete
    uni-11/complete
    uni-14/complete

The font has embedded bitmaps, but only one size. The "11" ones have
11px bitmap fonts and the "14" ones 14px bitmaps.
The "uni-" variant has much more glyphs.
Otherwise the differences are slim. From the font creation date the
"uni-" ones are newer.

[how]
Each font filename added to a cask is memorized. When the next fontfile
is to be added to the cask it is checked if we already have that
filename installed. Duplicates are then skipped.

If we have a deep archive, the fonts are added to the cask with full
relative path.

In case of Gohu that means the 11/complete variant is added (because all
files are alphabetically sorted before adding). By chance this is the
same variant that has historically been in the Cask, so no change here.

Fixes:

#1008 (comment)
Homebrew/homebrew-cask-fonts#6758 (comment)

Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 14, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants