From c20af957ee1d6af7a17b6c062a2771354164bf3f Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Sat, 22 Jun 2024 08:26:11 -0400 Subject: [PATCH] build: use the correct item: github.event.action --- .github/workflows/publish.yml | 33 ++------------------------------- 1 file changed, 2 insertions(+), 31 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 56d21f7cc..f6bc8b9b5 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -4,7 +4,6 @@ name: "Publish" on: - workflow_dispatch: repository_dispatch: types: - publish-testpypi @@ -22,37 +21,9 @@ concurrency: cancel-in-progress: true jobs: - dump_contexts_to_log: - runs-on: ubuntu-latest - steps: - - name: Dump GitHub context - env: - GITHUB_CONTEXT: ${{ toJson(github) }} - run: echo "$GITHUB_CONTEXT" - - name: Dump job context - env: - JOB_CONTEXT: ${{ toJson(job) }} - run: echo "$JOB_CONTEXT" - - name: Dump steps context - env: - STEPS_CONTEXT: ${{ toJson(steps) }} - run: echo "$STEPS_CONTEXT" - - name: Dump runner context - env: - RUNNER_CONTEXT: ${{ toJson(runner) }} - run: echo "$RUNNER_CONTEXT" - - name: Dump strategy context - env: - STRATEGY_CONTEXT: ${{ toJson(strategy) }} - run: echo "$STRATEGY_CONTEXT" - - name: Dump matrix context - env: - MATRIX_CONTEXT: ${{ toJson(matrix) }} - run: echo "$MATRIX_CONTEXT" - publish-to-test-pypi: name: "Publish to Test PyPI" - if: ${{ github.event.client_payload.event_type == 'publish-testpypi' }} + if: ${{ github.event.action == 'publish-testpypi' }} permissions: id-token: write # Needed for trusted publishing to PyPI. runs-on: "ubuntu-latest" @@ -76,7 +47,7 @@ jobs: publish-to-pypi: name: "Publish to PyPI" - if: ${{ github.event.client_payload.event_type == 'publish-pypi' }} + if: ${{ github.event.action == 'publish-pypi' }} permissions: id-token: write # Needed for trusted publishing to PyPI. runs-on: "ubuntu-latest"