Skip to content

Merge pull request #54 from secure-systems-lab/dependabot/github_acti… #151

Merge pull request #54 from secure-systems-lab/dependabot/github_acti…

Merge pull request #54 from secure-systems-lab/dependabot/github_acti… #151

Workflow file for this run

on: [push, pull_request]
name: build
jobs:
test:
strategy:
matrix:
go-version: [1.18.x, 1.19.x, 1.20.x]
os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Install Go
uses: actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe
with:
go-version: ${{ matrix.go-version }}
- name: Checkout code
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac
- name: Format Unix
if: runner.os == 'Linux'
run: test -z $(go fmt ./...)
- name: Test
run: go test -covermode atomic -coverprofile='profile.cov' ./...
- name: Send coverage
if: runner.os == 'Linux'
env:
COVERALLS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
GO111MODULE=off go get github.com/mattn/goveralls
$(go env GOPATH)/bin/goveralls -coverprofile=profile.cov -service=github
staticcheck:
name: "Run staticcheck"
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac
- uses: dominikh/staticcheck-action@ba605356b4b29a60e87ab9404b712f3461e566dc
with:
version: "2022.1"