Skip to content

Update labeler config#2983

Merged
delucis merged 2 commits intomainfrom
chris/fix-labeler-(maybe)
Mar 19, 2025
Merged

Update labeler config#2983
delucis merged 2 commits intomainfrom
chris/fix-labeler-(maybe)

Conversation

@delucis
Copy link
Copy Markdown
Member

@delucis delucis commented Mar 19, 2025

Description

This aims to fix the GitHub labeler action that runs for every PR for compatibility with v5.

Their docs are pretty bad, but IIUC, they introduced different match types which means we need to use a changed-files key for each of our existing labels.

@netlify
Copy link
Copy Markdown

netlify bot commented Mar 19, 2025

Deploy Preview for astro-starlight ready!

Name Link
🔨 Latest commit 4293a79
🔍 Latest deploy log https://app.netlify.com/sites/astro-starlight/deploys/67daed852d609600085e5ab5
😎 Deploy Preview https://deploy-preview-2983--astro-starlight.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 100 (no change from production)
Accessibility: 100 (no change from production)
Best Practices: 100 (no change from production)
SEO: 100 (no change from production)
PWA: -
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify site configuration.

@astrobot-houston
Copy link
Copy Markdown
Contributor

astrobot-houston commented Mar 19, 2025

size-limit report 📦

Path Size
/index.html 6.93 KB (0%)
/_astro/*.js 25.76 KB (0%)
/_astro/*.css 13.8 KB (0%)

Copy link
Copy Markdown
Contributor

@trueberryless trueberryless left a comment

Choose a reason for hiding this comment

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

One consideration about the new breaking labeler change

'🚨 action':
- .github/workflows/**
- changed-files:
- .github/workflows/**
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Do we want to increase the specificy by using

Suggested change
- .github/workflows/**
- any-glob-to-any-file: ".github/workflows/**"

This would later allow to make a list of the globs (if we ever need it) like this:

      - any-glob-to-any-file: [ ".github/workflows/**", "other glob"]

Comment on lines +3 to +5
'🚨 action':
- .github/workflows/**
- changed-files:
- .github/workflows/**
Copy link
Copy Markdown
Member

@HiDeoo HiDeoo Mar 19, 2025

Choose a reason for hiding this comment

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

Based on the examples, shouldn't the structure be something like this?

'🚨 action':
- changed-files:
  - any-glob-to-any-file:
    - .github/workflows/**

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Oh yeah… you’re right. Wow. What a terrible config format 😅

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

same brain 🧠

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I use it in my repos with "any-glob-to-any-files" and I'm not sure if it even works without, but I can confirm it works like this (example from some of my repos):

# See https://github.com/actions/labeler/tree/v5

"🚨 action":
  - changed-files:
      - any-glob-to-any-file: .github/workflows/**

"📝 changeset":
  - changed-files:
      - any-glob-to-any-file: "**/.changeset/**.{md,mdx}"

"🚧 config":
  - changed-files:
      - any-glob-to-any-file: "**/*config*.{js,ts,jsx,tsx,mjs,mts,json,yml,yaml,toml,cjs,cts}"

"✒️ documentation":
  - changed-files:
      - any-glob-to-any-file: "**/README.md"

"🌏 i18n":
  - changed-files:
      - all-globs-to-any-file: ["**/docs/**", "!**/docs/en/**"]

"🚀 manifest":
  - changed-files:
      - any-glob-to-any-file: "manifest*/**"

"📦 package":
  - changed-files:
      - any-glob-to-any-file: "**/packages/**"
      - any-glob-to-any-file: "**/package.json"

"🏯 styles":
  - changed-files:
      - any-glob-to-any-file: "**/*.{css,scss,sass,less,styl}"

@changeset-bot
Copy link
Copy Markdown

changeset-bot bot commented Mar 19, 2025

⚠️ No Changeset found

Latest commit: 4293a79

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@trueberryless
Copy link
Copy Markdown
Contributor

hahhaa, the desperation in the commit message is peak DX

Copy link
Copy Markdown
Contributor

@trueberryless trueberryless left a comment

Choose a reason for hiding this comment

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

LGTM 🎉

Copy link
Copy Markdown
Member

@HiDeoo HiDeoo left a comment

Choose a reason for hiding this comment

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

No idea if the indentation changes from 2 spaces to 4 spaces is valid, but otherwise looks similar to the (horrible) examples.

@delucis delucis merged commit 6276bf7 into main Mar 19, 2025
13 of 14 checks passed
@delucis delucis deleted the chris/fix-labeler-(maybe) branch March 19, 2025 16:20
HiDeoo added a commit to HiDeoo/starlight that referenced this pull request Mar 24, 2025
* main: (67 commits)
  [ci] format
  i18n(de): update `plugins.mdx` (withastro#2988)
  remove ghostcms plugin (withastro#2999)
  Add Starlight Markdown Blocks to community plugins (withastro#2998)
  [ci] release (withastro#2992)
  Add npm social icon (withastro#2969)
  [ci] format
  fix: Search ranking on merge indexes (withastro#2994)
  update astro to the latest version (withastro#2948)
  add own plugin and enhance some other descriptions (withastro#2996)
  chore: disable renovate dashboard (withastro#2995)
  feat(tailwind): support @astrojs/tailwind v6 (withastro#2991)
  i18n(fr): update `resources/plugins` (withastro#2990)
  i18n(ko-KR): update `plugins.mdx` (withastro#2987)
  chore: disable renovate package manager updates (withastro#2985)
  chore: disable renovate docker updates (withastro#2982)
  Update labeler config (withastro#2983)
  chore(deps): update github-actions (withastro#2979)
  [ci] format
  chore: disable automated PRs for npm (withastro#2978)
  ...
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.

4 participants