Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upconvert comment based action to be label based #834
Comments
|
In theory changing the event to |
|
Makes sense to me. I think that if the preview is successful, it could also remove the label. The instructions in https://github.com/nodejs/nodejs.dev/blame/695b54d12f249028b6120a2e7734fa6729e1e6b9/.github/PULL_REQUEST_TEMPLATE.md#L18 will also need to update if this is switched |
|
The job I referenced on core removes the label as soon as it is kicked off. I think there is an additional label added if it fails I would imagine that pattern would be worth following |
|
If we switch to labels does that mean only members can start the ci and create a preview link? |
|
Yes |
|
but folks with a triage role could kick it off as well |
|
Could be worth updating the PR template with a checkbox like this, if only so that triagers/maintainers know without having to specifically be asked:
As a bonus, the action could also auto-add the label if that is checked - though it wouldn't trigger the next workflow (because Actions can't trigger Actions), but we could add it to the same |
It works if you use a personal token (we can create one for @nodejs-github-bot and add it to the repo) |
|
Took a try with #851 |
|
Potentially, the label could be added to PULL_REQUEST_TEMPLATE frontmatter if a preview is wanted on all PRs |
The amazing @mmarchini made an action for nodejs/node that using labels to kick off CI
https://github.com/nodejs/node/blob/master/.github/workflows/auto-start-ci.yml
I think we should convert the existing comment based trigger to trigger based on a label. I believe that the above yml and the existing staging action have everything needed to accomplish this... we should not have to update any credentials (although we should update docs).
One thing... this might not be able to be previewed in a PR... so there might be some fancy fork work needed, or alternatively land and prod to see if it works.