* Update documentation contributing guidelines
* intentional error
* Revert "intentional error"
This reverts commit f77d2466d6.
67 lines
1.2 KiB
YAML
67 lines
1.2 KiB
YAML
name: Go
|
|
|
|
on:
|
|
push:
|
|
branches: [ master ]
|
|
pull_request:
|
|
branches: [ master ]
|
|
|
|
jobs:
|
|
|
|
tests:
|
|
runs-on: ${{ matrix.os }}
|
|
strategy:
|
|
matrix:
|
|
os: [ubuntu-latest, windows-latest]
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 1
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version: "1.18"
|
|
|
|
- name: Build
|
|
run: go build -v ./...
|
|
|
|
- name: Test
|
|
run: go test -v ./...
|
|
|
|
- uses: dominikh/staticcheck-action@v1.3.0
|
|
with:
|
|
version: "2022.1.3"
|
|
install-go: false
|
|
|
|
cross-compile:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 1
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version: "1.18"
|
|
|
|
- name: Cross-compile on all supported platforms
|
|
run: gen/xbuild.sh
|
|
|
|
formatting:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 1
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version: "1.18"
|
|
|
|
- name: Test `go fmt` creates no diffs
|
|
run: go fmt && git diff --exit-code
|
|
|