chore(workflows): add auto-labeler step to release draft workflow#2763
Merged
tusharmath merged 2 commits intomainfrom Apr 1, 2026
Merged
chore(workflows): add auto-labeler step to release draft workflow#2763tusharmath merged 2 commits intomainfrom
tusharmath merged 2 commits intomainfrom
Conversation
This was referenced Apr 1, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add an auto-labeler step to the release-drafter workflow so that PRs are automatically labeled based on rules defined in
release-drafter.yml.Context
The release-drafter workflow previously only updated the release draft on pushes to main. PRs were not being automatically labeled, requiring manual label assignment before merging. The
release-drafteraction supports anautolabelersub-action that reads label rules from the same config file and applies them to PRs onpull_request_targetevents.Changes
.github/workflows/release-drafter.ymlthat runs onpull_request_targetevents usingrelease-drafter/autolabeler@v7draft_release_update_job.rsin theforge_cicrate to include the corresponding auto-labeler step in the programmatically-generated workflow jobKey Implementation Details
The auto-labeler step is gated with
if: github.event_name == 'pull_request_target'so it only fires for PR events and not for push events (which trigger the release draft update). Both the hand-authored YAML and the Rust-generated workflow are kept in sync.Testing