actions: bump actions/setup-go from 4 to 5 #68
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 | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
permissions: # permissions for the Github token | |
contents: read | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: 1.21 | |
- name: Build | |
run: make build_all | |
- name: Test | |
run: make test | |
- name: Coverage | |
run: go test -coverprofile=cover.out ./... | |
- name: Report test-coverage to DeepSource | |
env: | |
DEEPSOURCE_DSN: ${{ secrets.DEEPSOURCE_DSN }} | |
run: | | |
# Install the CLI | |
curl https://deepsource.io/cli | sh | |
# Send the report to DeepSource | |
./bin/deepsource report --analyzer test-coverage --key go --value-file cover.out |