Skip to content

Commit

Permalink
Fixed Codecov uploader being run with the SHA of the merge commit ins…
Browse files Browse the repository at this point in the history
…tead of the HEAD commit when a job is run in a pull request context.
  • Loading branch information
binary1248 authored and ChrisThrasher committed Mar 23, 2023
1 parent bc5ddb3 commit b510042
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,9 @@ jobs:
retry_wait_seconds: 60
warning_on_retry: false
shell: bash
command: ./${{ env.CODECOV_BINARY }} -n "${{ matrix.platform.name }} ${{ matrix.config.name }} ${{ matrix.type.name }}" -Z -f ./build/coverage.out -C ${{ github.sha }} -s ./build -e CODECOV_TOKEN,GITHUB_ACTION,GITHUB_RUN_ID,GITHUB_REF,GITHUB_REPOSITORY,GITHUB_SHA,GITHUB_HEAD_REF
command: |
if [[ "${{ github.event_name }}" == "pull_request" || "${{ github.event_name }}" == "pull_request_target" ]]; then COMMIT_OVERRIDE="-C ${{ github.event.pull_request.head.sha }}"; fi
./${{ env.CODECOV_BINARY }} -n "${{ matrix.platform.name }} ${{ matrix.config.name }} ${{ matrix.type.name }}" -Z -f ./build/coverage.out $COMMIT_OVERRIDE -s ./build -e CODECOV_TOKEN,GITHUB_ACTION,GITHUB_RUN_ID,GITHUB_REF,GITHUB_REPOSITORY,GITHUB_SHA,GITHUB_HEAD_REF
- name: Test Install Interface
if: matrix.platform.name != 'Android' && matrix.config.name != 'iOS'
Expand Down

0 comments on commit b510042

Please sign in to comment.