Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cask/audit: fix sharding for font-* casks #17311

Merged
merged 2 commits into from
May 16, 2024

Conversation

bevanjkay
Copy link
Member

@bevanjkay bevanjkay commented May 16, 2024

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same change?
  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes? Here's an example.
  • Have you successfully run brew style with your changes locally?
  • Have you successfully run brew typecheck with your changes locally?
  • Have you successfully run brew tests with your changes locally?

The primary issue at hand here is about sharding files, not identifying "font casks", so this PR proposes a change that moves the casks to an appropriate folder solely based on the token.

We currently don't have any logic that separates a "font cask" from an "application cask", but perhaps we should have a separate audit for new casks that requires the font- prefix when a cask only includes font artifacts.


If we like this route it depends on Homebrew/homebrew-cask#173942

Copy link
Member

@MikeMcQuaid MikeMcQuaid left a comment

Choose a reason for hiding this comment

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

Thanks @bevanjkay (and @p-linnane for the idea for the original approach!)

@bevanjkay
Copy link
Member Author

@MikeMcQuaid Does this repo allow merging without CI passing, otherwise there's a chicken and egg problem I think?

@p-linnane
Copy link
Member

We can open a cask rename PR, and then rerun this.

@bevanjkay
Copy link
Member Author

bevanjkay commented May 16, 2024

I have done that, but it fails the audit because it breaks the current rules (before this PR).
We can add a label to skip, but we'd need a full audit skip label which I feel like is dangerous.

Homebrew/homebrew-cask#173942

@p-linnane
Copy link
Member

I misunderstood. I thought the plan was to rename those font-* casks that are not actual fonts first, rather than just move them to the font-* directory.

@MikeMcQuaid
Copy link
Member

Does this repo allow merging without CI passing, otherwise there's a chicken and egg problem I think?

It does not.

It's perhaps just removing the audit entirely in this PR until after it is merged and fixed here and homebrew-cask.

@MikeMcQuaid
Copy link
Member

I misunderstood. I thought the plan was to rename those font-* casks that are not actual fonts first, rather than just move them to the font-* directory.

This was my understanding, too. If this will fix the issue: let's do that.

@MikeMcQuaid
Copy link
Member

Note, from #17305 (comment)

Seems we need to update the docs here, too.

@bevanjkay
Copy link
Member Author

Is there a specific reason that the tokens need to be adjusted other than to get past the CI issue here?

I'm okay if you feel it is too confusing and keep the remane, but I think requiring the usual token standards (Font Finagler.app - remains as font-finagler) and also that a "font" has the font-* prefix is okay. It seems less confusing to me than having an exception for when the standard token would start with font-* to remove the dashes.

@MikeMcQuaid
Copy link
Member

Is there a specific reason that the tokens need to be adjusted other than to get past the CI issue here?

Yes. We want to make it easier for both contributors and https://github.com/Homebrew/homebrew-linux-fonts

It seems less confusing to me than having an exception for when the standard token would start with font-* to remove the dashes.

We're already introducing a bunch of exceptions for fonts in the code so it feels no worse to make a one-off exception in the docs, too.

@MikeMcQuaid MikeMcQuaid merged commit 1fac683 into Homebrew:master May 16, 2024
25 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants