The good: We’re successfully triggering actions on labels by filtering on label created events:
on: pull_request: types: [labeled] ... if: github.event.label.name == 'do-thingy'
The unclear: When a PR has a specific pre-existing label… we want to opt-out and NOT do the thingy. The confusing part is how to tell what labels already exist on the PR, vs. on the trigger action, so we can check for a preexisting opt-out label.
Ideally something like
### Psuedo-code (does not work, but would like it to!) on: pull_request: #any action on a PR ... if: not_in(github.pr.labels, 'skip_ci')
… but we can’t figure it out.
Any way to check the active labels on a PR as part of an
if check? Or some other way to do this?