Skip to content

Commit 8e7ddc5

Browse files
authored
Merge pull request #138 from per1234/codecov-upload-fail-conditional
Don't require Codecov upload success for test run in fork
2 parents 737ee0b + 12e5994 commit 8e7ddc5

File tree

3 files changed

+4
-2
lines changed

3 files changed

+4
-2
lines changed

workflow-templates/dependabot/workflow-template-copies/.github/workflows/test-go-task.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,4 +73,4 @@ jobs:
7373
with:
7474
file: ${{ matrix.module.path }}coverage_unit.txt
7575
flags: ${{ matrix.module.codecov-flags }}
76-
fail_ci_if_error: true
76+
fail_ci_if_error: ${{ github.repository == 'REPO_OWNER/REPO_NAME' }}

workflow-templates/test-go-task.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ Configure the version of Go used for development of the project in the `env.GO_V
2525

2626
If the project contains Go modules in paths other than the root of the repository, add their paths to the [job matrix](https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idstrategymatrix) in `check-go-task.yml` at `jobs.test.strategy.matrix.module[].path` and the [Codecov flag](https://docs.codecov.com/docs/flags) to group their data under at `jobs.test.strategy.matrix.module[].codecov-flags`
2727

28+
Replace `REPO_OWNER/REPO_NAME` with the repository's name (e.g., `arduino/arduino-cli`) in the `codecov/codecov-action` action's `fail_ci_if_error` input in `test-go-task.yml`.
29+
2830
#### `.gitignore`
2931

3032
Add the following to `.gitignore`:

workflow-templates/test-go-task.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,4 +73,4 @@ jobs:
7373
with:
7474
file: ${{ matrix.module.path }}coverage_unit.txt
7575
flags: ${{ matrix.module.codecov-flags }}
76-
fail_ci_if_error: true
76+
fail_ci_if_error: ${{ github.repository == 'REPO_OWNER/REPO_NAME' }}

0 commit comments

Comments
 (0)