Skip to content

misc: Add labeler workflow to automatically label PRs based on files changed#3151

Open
erin-le wants to merge 2 commits into
gem5:developfrom
erin-le:labeler-action
Open

misc: Add labeler workflow to automatically label PRs based on files changed#3151
erin-le wants to merge 2 commits into
gem5:developfrom
erin-le:labeler-action

Conversation

@erin-le
Copy link
Copy Markdown
Contributor

@erin-le erin-le commented May 8, 2026

This PR adds a workflow to automatically assign labels to PRs based on the files changed. The path rules in labeler.yml were written based on how labels have typically been assigned in the gem5 repository in the past. The discussion for this workflow can be seen in #3095, and the work for this workflow was started by @lhartung.

This automatically labels pull requests based on some simple file path
rules.
@erin-le erin-le marked this pull request as ready for review May 8, 2026 00:52
Copilot AI review requested due to automatic review settings May 8, 2026 00:52
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds a GitHub Actions workflow to automatically apply repository labels to pull requests based on the paths of changed files, using a central .github/labeler.yml ruleset. This helps keep labeling consistent and reduces manual triage overhead.

Changes:

  • Added a new Pull Request Labeler workflow using actions/labeler.
  • Introduced .github/labeler.yml with path-based label rules for major gem5 subsystems.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
.github/workflows/label.yaml Adds the GitHub Actions workflow which runs the labeler on PRs.
.github/labeler.yml Defines the path/glob rules mapping changed files to labels.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .github/workflows/label.yaml Outdated
@erin-le erin-le added the misc Anything outside of the current labeling categories label May 8, 2026
@erin-le erin-le requested a review from BobbyRBruce May 8, 2026 05:09
Copilot AI review requested due to automatic review settings May 13, 2026 01:17
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

Comment thread .github/labeler.yml Outdated
Comment on lines +149 to +153
- all-globs-to-any-file: [src/sim/**, '!src/sim/se_workload.**', '!src/sim/syscall**.**', '!src/sim/process.**']

sim-se:
- changed-files:
- any-glob-to-any-file: ['**/se_**.**', '**/syscall**.**', '**/se_binary_workload.py', src/sim/process.**, src/sim/fd_**.**]
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@BobbyRBruce: Do you know if process_impl.hh falls under sim-se? I skimmed through the commit messages in process_impl.hh and none of the ones I saw mentioned SE mode specifically. Many of the commit messages were quite old, however, so that may play a role in SE mode not being mentioned.

This commit extends the labeler action to include all relevant
labels and corresponding path globs.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

misc Anything outside of the current labeling categories

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants