fix: scope labeler trigger to opened/synchronize and fix bugfix typo

- Restrict pull-request-target.yml to only 'opened' and 'synchronize'
  events to reduce unnecessary API calls that exhaust the rate limit
- Fix 'bugpost' typo back to 'bugfix' in pr_enforce_labels.yml
This commit is contained in:
James Rich 2026-04-09 12:19:03 -05:00
parent 750c4ea928
commit 93e711e0f2
2 changed files with 7 additions and 4 deletions

View file

@ -18,7 +18,7 @@ jobs:
script: |
// Extract labels from the payload directly to avoid extra API calls
const latestLabels = context.payload.pull_request.labels.map(label => label.name);
const requiredLabels = ['bugpost', 'enhancement', 'automation', 'dependencies', 'repo', 'release', 'refactor'];
const requiredLabels = ['bugfix', 'enhancement', 'automation', 'dependencies', 'repo', 'release', 'refactor'];
console.log('Labels from payload:', latestLabels);
const hasRequiredLabel = latestLabels.some(label => requiredLabels.includes(label));
if (!hasRequiredLabel) {