-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Refactor workflows for new typescript-bot triggers #57409
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
Conversation
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.
Just something I noticed while going over the new triggering workflows.
branch_name: | ||
description: Release branch name to create | ||
required: true | ||
type: number |
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.
Shouldn't this be string
?
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.
You're totally right, copy paste error, blah
branch_name: | ||
description: Release branch name to create | ||
required: true | ||
type: number |
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.
Here, too.
required: true | ||
type: number |
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.
Also here.
This goes with microsoft/typescript-bot-test-triggerer#36.
Every action now uses a workflow dispatch (not a repo dispatch; the former is newer), along with new parameters for data sent by the bot. These options must always be defined for workflows the bot calls.
The composite action
.github/actions/post-workflow-result/action.yml
is used to share code between actions for updating the status comment and posting results. All of our workflows that trigger the bot use this, except the "repros" workflow, which has its own code for stuff (which I will just not touch for now).I'm not using a "reusable workflow" for this, as those jobs run in an entirely different unrelated context, whereas composite actions are just sorta jammed into an existing workflow (which is nice).
Most workflows don't change much, save for the cherry-pick action, which surprisingly was the only action that actually replied back.