[codecov] Use v4 of the uploader #95
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: go ci build | |
"on": | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
permissions: | |
contents: read | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Go | |
uses: actions/setup-go@v4 | |
with: | |
go-version-file: 'go.mod' | |
- name: Install go dependencies | |
run: go get . | |
- name: Build | |
run: go build -v ./... | |
- name: Test | |
run: go test ./... -cover -json > TestResults.json | |
- name: Cat results | |
if: always() | |
run: cat TestResults.json | |
- name: Upload coverage reports to Codecov | |
uses: codecov/codecov-action@v4.0.1 | |
env: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
slug: cacoco/codemetagenerator |