From 3d2320456cc31b8d733e94fd76c379655b0a5bf5 Mon Sep 17 00:00:00 2001 From: Gerd Date: Tue, 27 May 2025 17:42:51 +0200 Subject: [PATCH] update --- .github/workflows/test.yml | 43 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 .github/workflows/test.yml diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 000000000..2d3a3aebc --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,43 @@ +name: Test +on: + workflow_dispatch: +permissions: + actions: write + contents: write + issues: write +jobs: + relabel-issues: + runs-on: ubuntu-latest + steps: + - name: search + uses: actions/github-script@v7 + id: find_issues + with: + script: | + const issues = await github.paginate( + github.rest.issues.listForRepo, + { + owner: context.repo.owner, + repo: context.repo.repo, + state: 'open', + labels: 'scheduled-next-release', + per_page: 100, + } + ); + return issues.map(issue => issue.number); + + - name: remove + if: steps.find_issues.outputs.result != '[]' + uses: actions-ecosystem/action-remove-labels@v1 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + labels: scheduled-next-release + number: ${{ fromJson(steps.find_issues.outputs.result)[0] }} + + - name: add + if: steps.find_issues.outputs.result != '[]' + uses: actions-ecosystem/action-add-labels@v1 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + labels: fixed-pending-release + number: ${{ fromJson(steps.find_issues.outputs.result)[0] }}