Skip to content

Update build.yml

Update build.yml #1

Workflow file for this run

name: build
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
name: check
runs-on: ubuntu-latest
steps:
- name: setup
uses: actions/setup-go@v2
with:
go-version: ^1.16
- name: checkout
uses: actions/checkout@v2
- name: fmt
run: diff -u <(echo -n) <(gofmt -d -s .)
- name: vet
run: go vet ./...
- name: golangci-lint
uses: golangci/golangci-lint-action@v2
- name: test
run: go test -v -race -coverprofile=coverage.txt -covermode=atomic ./...
- name: codecov
uses: codecov/codecov-action@v1