chore: update go in github action
parent
1d21b41462
commit
fb811d0913
|
@ -1,6 +1,12 @@
|
|||
name: Go
|
||||
|
||||
on: [push, pull_request]
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
pull_request:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
test:
|
||||
|
@ -10,21 +16,20 @@ jobs:
|
|||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-go@v2
|
||||
with:
|
||||
go-version: 1.16
|
||||
- run: go version
|
||||
go-version: "~1.16"
|
||||
- run: go test -race ./...
|
||||
build-gotip:
|
||||
name: Build using gotip
|
||||
runs-on: ubuntu-latest
|
||||
build:
|
||||
name: Build
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-latest, macos-latest, windows-latest]
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-go@v2
|
||||
with:
|
||||
go-version: 1.16
|
||||
- run: go get golang.org/dl/gotip
|
||||
- run: gotip download
|
||||
- run: gotip version
|
||||
- run: gotip build main.go
|
||||
go-version: "~1.16"
|
||||
- run: go build
|
||||
lint:
|
||||
name: Lint
|
||||
runs-on: ubuntu-latest
|
||||
|
@ -32,4 +37,4 @@ jobs:
|
|||
- uses: actions/checkout@v2
|
||||
- uses: golangci/golangci-lint-action@v2
|
||||
with:
|
||||
version: v1.37
|
||||
version: latest
|
||||
|
|
Loading…
Reference in New Issue