feat: add boa_wintertc crate skeleton for WinterTC compliance #74
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: PR Management | |
| on: | |
| pull_request_target: | |
| types: [opened, reopened, synchronize, closed] | |
| jobs: | |
| manage_pr: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| pull-requests: write | |
| issues: write | |
| steps: | |
| - name: Auto Add Label | |
| if: github.event.action == 'opened' || github.event.action == 'reopened' || github.event.action == 'synchronize' | |
| uses: actions/github-script@v8 | |
| with: | |
| script: | | |
| github.rest.issues.addLabels({ | |
| issue_number: context.issue.number, | |
| owner: context.repo.owner, | |
| repo: context.repo.repo, | |
| labels: ['waiting-for-review'] | |
| }) | |
| - name: Auto Remove Label | |
| if: github.event.action == 'closed' | |
| uses: actions/github-script@v8 | |
| continue-on-error: true | |
| with: | |
| script: | | |
| try { | |
| await github.rest.issues.removeLabel({ | |
| issue_number: context.issue.number, | |
| owner: context.repo.owner, | |
| repo: context.repo.repo, | |
| name: 'waiting-for-review' | |
| }); | |
| } catch (error) { | |
| console.log('Label "waiting-for-review" not found or could not be removed.'); | |
| } | |
| - name: Auto Assign Milestone | |
| if: github.event.action == 'opened' | |
| uses: actions/github-script@v8 | |
| with: | |
| script: | | |
| // Fetch open milestones and assign the closest one | |
| const { data: milestones } = await github.rest.issues.listMilestones({ | |
| owner: context.repo.owner, | |
| repo: context.repo.repo, | |
| state: 'open', | |
| sort: 'due_on', | |
| direction: 'asc' | |
| }); | |
| if (milestones.length > 0) { | |
| const latestMilestone = milestones[0]; | |
| await github.rest.issues.update({ | |
| issue_number: context.issue.number, | |
| owner: context.repo.owner, | |
| repo: context.repo.repo, | |
| milestone: latestMilestone.number | |
| }); | |
| } |