2021-05-27 15:50:10 +03:00
|
|
|
name: build
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
2021-05-29 13:05:28 +03:00
|
|
|
- main
|
2021-05-27 15:50:10 +03:00
|
|
|
pull_request:
|
|
|
|
types: [opened, synchronize, reopened]
|
|
|
|
|
|
|
|
jobs:
|
2021-08-03 16:51:01 +03:00
|
|
|
check:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
- uses: reviewdog/action-staticcheck@v1
|
|
|
|
with:
|
|
|
|
github_token: ${{ secrets.github_token }}
|
|
|
|
reporter: github-pr-review
|
|
|
|
filter_mode: nofilter
|
|
|
|
fail_on_error: true
|
|
|
|
|
2021-05-27 15:50:10 +03:00
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
2021-05-28 16:35:34 +03:00
|
|
|
fail-fast: false
|
2021-05-27 15:50:10 +03:00
|
|
|
matrix:
|
2021-06-22 19:49:56 +03:00
|
|
|
go: [1.15, 1.16]
|
2021-05-27 15:50:10 +03:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Setup Go
|
|
|
|
uses: actions/setup-go@v2
|
|
|
|
with:
|
2021-05-28 16:35:34 +03:00
|
|
|
go-version: "${{ matrix.go }}"
|
2021-05-27 15:50:10 +03:00
|
|
|
- name: Build
|
|
|
|
run: |
|
|
|
|
go vet ./...
|
|
|
|
go test -v ./...
|
|
|
|
go build ./...
|