-
Notifications
You must be signed in to change notification settings - Fork 162
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create preview PRs using labels #1767
Conversation
bad6acc
to
249dfd8
Compare
249dfd8
to
6669fcc
Compare
860dede
to
6669fcc
Compare
6669fcc
to
f55317a
Compare
f55317a
to
a0d2ef3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not the best person to give a thorough review of GitHub actions from a technical perspective, but the functionality looks great. I haven't seen this approach used before -- did you see it elsewhere or come up with it yourself?
The idea popped in my head while working on #1765. I searched online for "trigger on label" which led me to a StackOverflow example, and I took it from there. |
Benefits: 1. Ease of use - straight from the PR page 2. Workflow runs will show on the PR checks¹ 3. Downstream PRs will be automatically updated with new PR changes 4. Simplified logic in reusable workflow ¹ In the case that a preview label already exists and another preview label is added, this results in the workflow for the label that already exists to appear as "skipped" because it has been skipped on the latest event trigger to avoid an unnecessary update.
a0d2ef3
to
90b7dee
Compare
I'll merge this now since this is a change on the dev side that we can iterate on. |
Did anyone ensure that labels can only be added by us and not random other GitHub users? Because I'm pretty sure anyone can add labels… and that's not what we want here. |
That's a good concern, it hadn't crossed my mind. But I don't think anyone can add labels... I just tried on a random PR I had opened in bioconda-recipes and don't see a way to add a label other than tagging From GitHub docs:
|
Yay, that's great. I'm not sure why I recalled being able to add labels to issues/PRs I've created in third-party repos… |
Description of proposed changes
Benefits:
¹ In the case that a preview label already exists and another preview
label is added, this results in the workflow for the label that already
exists to appear as "skipped" because it has been skipped on the latest
event trigger to avoid an unnecessary update.
Checklist
If making user-facing changes, add a message in CHANGELOG.md summarizing the changes in this PRno functional changes