Update Go version to 1.20 #874
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: CI | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
jobs: | |
yamllint: | |
name: lint yaml | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup Python | |
uses: actions/setup-python@v1 | |
- name: Install yamllint | |
run: pip install --user yamllint | |
- name: Run yamllint | |
run: ~/.local/bin/yamllint -c .yamllint.yml . | |
golangci: | |
name: lint | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/setup-go@v3 | |
with: | |
go-version: 1.20.x | |
- uses: actions/checkout@v3 | |
- name: golangci-lint | |
uses: golangci/golangci-lint-action@v3 | |
with: | |
version: v1.53 | |
args: --timeout 5m | |
checkproto: | |
name: check proto | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Run check-proto | |
run: make check-proto | |
checkgomod: | |
name: check go.mod | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-go@v1 | |
with: | |
go-version: 1.20.x | |
- run: go mod tidy -v | |
- name: Check for changes in go.mod | |
run: | | |
git diff --name-only --exit-code go.mod || ( git diff && echo "Run go tidy to update go.mod" && false ) | |
build: | |
name: build go | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-go@v1 | |
with: | |
go-version: 1.20.x | |
- run: | | |
go build -v ./... | |
unittest: | |
name: unit test | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-go@v1 | |
with: | |
go-version: 1.20.x | |
- run: | | |
go test -v ./... |