Update version resync-prune-node.sh #897
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: State Change Labels | |
| on: | |
| pull_request: | |
| types: [opened, labeled, unlabeled, synchronize] | |
| paths-ignore: | |
| - '.github/**' | |
| jobs: | |
| label: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| issues: write | |
| pull-requests: write | |
| steps: | |
| - name: Check State Change Labels | |
| uses: mheap/github-action-required-labels@v5 | |
| with: | |
| mode: exactly | |
| count: 1 | |
| labels: | | |
| stateChange | |
| noStateChange | |
| - name: Check Backport Labels | |
| uses: actions/github-script@v7 | |
| with: | |
| script: | | |
| const { data: labels } = await github.rest.issues.listLabelsOnIssue({ | |
| owner: context.repo.owner, | |
| repo: context.repo.repo, | |
| issue_number: context.issue.number | |
| }); | |
| const labelNames = labels.map(label => label.name); | |
| // Check for exactly one backport release label | |
| const backportLabels = labelNames.filter(name => | |
| name.startsWith('backport release/') | |
| ); | |
| if (backportLabels.length !== 1) { | |
| throw new Error(`Expected exactly 1 backport release label, found: ${backportLabels.length} (${backportLabels.join(', ')})`); | |
| } | |
| console.log(`✅ Found backport label: ${backportLabels[0]}`); |