From b807fbe0ad87a8cff06f88415e44d2d1a1099b42 Mon Sep 17 00:00:00 2001 From: Scott K Logan Date: Fri, 24 May 2024 10:52:13 -0700 Subject: [PATCH] Allow use of CODECOV_TOKEN to enable codecov upload (#30) --- .github/workflows/pytest.yaml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/pytest.yaml b/.github/workflows/pytest.yaml index 2f5e604..e5119ca 100644 --- a/.github/workflows/pytest.yaml +++ b/.github/workflows/pytest.yaml @@ -25,6 +25,10 @@ on: # yamllint disable-line rule:truthy default: 'colcon/ci' required: false type: string + secrets: + CODECOV_TOKEN: + description: 'token to use when running codecov action after testing' + required: false jobs: setup: @@ -59,3 +63,7 @@ jobs: - uses: ./.github-ci-action-repo - uses: codecov/codecov-action@v3 if: ${{ inputs.codecov }} + - uses: codecov/codecov-action@v4 + env: + CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} + if: ${{ env.CODECOV_TOKEN != '' }}