Skip to content
This repository has been archived by the owner on Sep 29, 2024. It is now read-only.

CI

CI #253

Workflow file for this run

name: CI
permissions:
contents: read
on:
push:
branches: [master]
pull_request:
branches: [master]
schedule:
- cron: '0 8 * * 1' # run "At 08:00 on Monday"
jobs:
build:
name: ${{ matrix.os }} Go (${{ matrix.go }})
timeout-minutes: 5
strategy:
matrix:
go: ['stable','oldstable']
os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Install Go 1.x
uses: actions/setup-go@v4
with:
go-version: ${{ matrix.go }}
check-latest: true
- name: Check out code into the Go module directory
uses: actions/checkout@v3
- name: Check go version
run: go version
- name: Go Format
run: gofmt -s -w . && git diff --exit-code
- name: Go Tidy
run: go mod tidy && git diff --exit-code
- name: Go Mod Verify
run: go mod verify
- name: Run linter
uses: golangci/golangci-lint-action@v3
with:
version: latest
skip-cache: true
skip-pkg-cache: true
skip-build-cache: true
- name: Run tests
run: |
make test
- name: Run benchmarks
run: |
make bench