-
Notifications
You must be signed in to change notification settings - Fork 0
59 lines (54 loc) · 1.98 KB
/
coverage-upload.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
name: 'Coverage upload'
on:
workflow_run:
workflows: ["CI"]
types: [completed]
jobs:
fetch-info:
name: Fetch triggering workflow metadata
runs-on: ubuntu-latest
permissions:
contents: read
checks: write # For the check run creation !
steps:
- name: 'Check run ○'
uses: yoanm/temp-reports-group-workspace/.github/actions/attach-check-run-to-triggering-workflow-action@develop
with:
name: 'Fetch coverage info'
fails-on-triggering-workflow-failure: true
- uses: yoanm/temp-reports-group-workspace/.github/actions/fetch-workflow-metadata-action@develop
id: fetch-workflow-metadata
outputs:
commit-sha: ${{ steps.fetch-workflow-metadata.outputs.commit-sha }}
run-id: ${{ steps.fetch-workflow-metadata.outputs.run-id }}
codacy-uploader:
name: Codacy
needs: [fetch-info]
uses: yoanm/temp-reports-group-workspace/.github/workflows/codacy-upload-from-artifacts.yml@develop
permissions:
contents: read
checks: write # For the check run creation !
secrets:
PROJECT_TOKEN: ${{ secrets.CODACY_PROJECT_TOKEN }}
with:
artifact: coverage-group
run-id: ${{ needs.fetch-info.outputs.run-id }}
language: go
force-coverage-parser: go
codecov-uploader:
name: Codecov
needs: [fetch-info]
uses: yoanm/temp-reports-group-workspace/.github/workflows/codecov-upload-from-artifacts.yml@develop
permissions:
contents: read
checks: write # For the check run creation !
secrets:
TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
artifact: coverage-group
run-id: ${{ needs.fetch-info.outputs.run-id }}
override-commit: ${{ needs.fetch-info.outputs.commit-sha }}
override-branch: ${{ needs.fetch-info.outputs.branch }}
override-pr: ${{ needs.fetch-info.outputs.pr-number }}
override-build: ${{ needs.fetch-info.outputs.run-id }}
override-build-url: ${{ needs.fetch-info.outputs.run-url }}