lint check addition #21
This file contains hidden or 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: Build and Test Workflow | |
on: | |
push: | |
branches: [ "linting" ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
max-parallel: 30 | |
matrix: | |
version: | |
- 'oldstable' | |
- 'stable' | |
steps: | |
- name: Checkout Code | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 | |
- name: Setup Go | |
uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a | |
with: | |
go-version: ${{ matrix.version }} | |
- name: Run golangci-lint | |
uses: golangci/golangci-lint-action@08e2f20817b15149a52b5b3ebe7de50aff2ba8c5 | |
- name: Test Go | |
run: go test -v -coverprofile=coverage.out ./... | |
- name: Build Go | |
run: go build ./... | |
- name: Upload coverage report | |
uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 | |
with: | |
path: coverage.out | |
name: coverage-report-${{matrix.version}} | |
- name: Display coverage report | |
run: go tool cover -func=coverage.out | |