Skip to content

ci: gate build, unit-test, and lint workflows on CI-Run label#582

Open
bhatnitish wants to merge 2 commits into
ROCm:mainfrom
bhatnitish:rocm-label-gated-ci
Open

ci: gate build, unit-test, and lint workflows on CI-Run label#582
bhatnitish wants to merge 2 commits into
ROCm:mainfrom
bhatnitish:rocm-label-gated-ci

Conversation

@bhatnitish

Copy link
Copy Markdown
Contributor

Summary

  • Build, Unit Tests, and Linting workflows now only run on PRs when the CI-Run label is present
  • Workflows fire on the labeled event type; jobs have an if condition checking for the label
  • Linting retains its push to main trigger so it still runs after merges

Behavior

Event CI-Run label present Runs?
PR opened / new commits pushed No
Label CI-Run added to PR Yes Yes
Push to main (linting only) N/A Yes

Notes

  • Who can add the CI-Run label is controlled via GitHub repo settings (triage role or above) — no workflow changes needed for that
  • The CI-Run label needs to be created in the repo under Issues → Labels

Workflows now trigger only when the 'CI-Run' label is added to a PR,
preventing automatic CI on every push. Who can apply the label is
controlled via GitHub repo permissions (triage role or above).

Linting retains its push-to-main trigger for post-merge runs.
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.

1 participant