name: CI on: [push, pull_request] jobs: test-and-coverage: strategy: matrix: os: [macos-latest, windows-latest, ubuntu-latest] runs-on: ${{ matrix.os }} steps: - name: Check out repository uses: actions/checkout@v4 - name: Setup go uses: actions/setup-go@v5 with: go-version-file: './go.mod' - name: Test run: make tests - name: Setup go with oldstable version for lcov if: matrix.os == 'ubuntu-latest' uses: actions/setup-go@v5 with: go-version: 'oldstable' - name: Convert Go coverage to lcov if: matrix.os == 'ubuntu-latest' run: | go install github.com/jandelgado/gcov2lcov@latest gcov2lcov -infile=coverage.out -outfile=coverage.lcov - name: Upload coverage to Coveralls if: matrix.os == 'ubuntu-latest' uses: coverallsapp/github-action@v2 format-markdown: runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v4 - name: Format Markdown with markdownlint run: | npm install -g markdownlint-cli markdownlint --disable MD013 --fix . --ignore CODE_OF_CONDUCT.md git add -A git diff --cached --exit-code