Skip to content

fix: stabilize CI and trim README drift #3

fix: stabilize CI and trim README drift

fix: stabilize CI and trim README drift #3

Workflow file for this run

name: ci
on:
push:
branches: [main]
pull_request:
permissions:
contents: read
jobs:
test:
name: test (go ${{ matrix.go-version }} / ${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
go-version: ['1.26']
steps:
- uses: actions/checkout@v6
- uses: actions/setup-go@v6
with:
go-version: ${{ matrix.go-version }}
cache: true
- name: gofmt check
shell: bash
run: |
mapfile -t files < <(git ls-files '*.go')
if [ "${#files[@]}" -eq 0 ]; then
exit 0
fi
out="$(gofmt -l "${files[@]}")"
if [ -n "$out" ]; then
printf '%s\n' "$out"
exit 1
fi
- name: go vet
run: go vet ./...
- name: go test
run: go test ./...
- name: go build
run: go build ./cmd/msx
race:
name: race (ubuntu-latest)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-go@v6
with:
go-version: '1.26'
cache: true
- name: go test -race
run: go test -race ./...