diff --git a/.github/workflows/add-label-to-new-issue.yml b/.github/workflows/add-label-to-new-issue.yml deleted file mode 100644 index e35f68a2b..000000000 --- a/.github/workflows/add-label-to-new-issue.yml +++ /dev/null @@ -1,38 +0,0 @@ -name: Add label to new issue - -on: - issues: - types: [opened] - pull_request: - types: [opened] - -jobs: - label-new-issue: - runs-on: ubuntu-latest - permissions: - issues: write - pull-requests: write - steps: - - uses: actions/github-script@v6 - with: - script: | - const issue = await github.rest.issues.get({ - owner: context.issue.owner, - repo: context.issue.repo, - issue_number: context.issue.number - }); - - const statusLabel = issue.data.labels.find(({ name }) => - name.startsWith("status:") - ); - - if (statusLabel === undefined) { - await github.rest.issues.addLabels({ - owner: context.issue.owner, - repo: context.issue.repo, - issue_number: context.issue.number, - labels: ["status:triaging"] - }); - } else { - console.log(`Issue already has a status: ${statusLabel.name}`); - }