blob: 855e59444b0997f72c5c9cd910dee68815cc1cda [file] [log] [blame]
name: build
on: [push]
jobs:
build:
strategy:
matrix:
go-version: [1.15, 1.16, 1.17, 1.18]
os: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: ${{ matrix.go-version }}
- name: Checkout code
uses: actions/checkout@v2
- name: Build
run: |
GOOS=freebsd go build
GOOS=windows go build
go build -v .
- name: Test
run: |
go vet
go test -v -race -coverprofile=coverage.txt -covermode=atomic
- name: After success
run: |
bash <(curl -s https://codecov.io/bash)