diff --git a/.github/workflows/e2e-couchdb.yml b/.github/workflows/e2e-couchdb.yml index ccd496d0bd..eb3f6b5583 100644 --- a/.github/workflows/e2e-couchdb.yml +++ b/.github/workflows/e2e-couchdb.yml @@ -41,3 +41,16 @@ jobs: uses: actions/upload-artifact@v3 with: path: html-test-results + - name: Remove pr:e2e:couchdb label (if present) + if: ${{ contains(github.event.pull_request.labels.*.name, 'pr:e2e:couchdb') }} + uses: actions/github-script@v6 + with: + script: | + const { owner, repo, number } = context.issue; + const labelToRemove = 'pr:e2e:couchdb'; + await github.rest.issues.removeLabel({ + owner, + repo, + issue_number: number, + name: labelToRemove + }); diff --git a/.github/workflows/e2e-pr.yml b/.github/workflows/e2e-pr.yml index 5e57bf2085..3c6f5accc6 100644 --- a/.github/workflows/e2e-pr.yml +++ b/.github/workflows/e2e-pr.yml @@ -66,3 +66,16 @@ jobs: repo: "openmct", body: 'Failure ❌ ! Build artifacts are here: https://github.com/nasa/openmct/actions/runs/' + context.runId }) + - name: Remove pr:e2e label (if present) + if: ${{ contains(github.event.pull_request.labels.*.name, 'pr:e2e') }} + uses: actions/github-script@v6 + with: + script: | + const { owner, repo, number } = context.issue; + const labelToRemove = 'pr:e2e'; + await github.rest.issues.removeLabel({ + owner, + repo, + issue_number: number, + name: labelToRemove + });