okami.mom/ultraviolet

git clone https://git.nkp.pet/okami.mom/ultraviolet

Kieran Klukasfeat: scope push to main19049f2

main
829 B34 linesraw
1name: coverage
2# push is scoped to main so a push to a PR branch fires only the
3# pull_request run, not both. Merges to main still run via push.
4on:
5  push:
6    branches: [main]
7  pull_request:
8
9jobs:
10  coverage:
11    strategy:
12      matrix:
13        go-version: [^1]
14        os: [ubuntu-latest, windows-latest, macos-latest]
15    runs-on: ${{ matrix.os }}
16    env:
17      GO111MODULE: "on"
18    steps:
19      - name: Install Go
20        uses: actions/setup-go@v7
21        with:
22          go-version: ${{ matrix.go-version }}
23
24      - name: Checkout code
25        uses: actions/checkout@v7
26
27      - name: Coverage
28        run: |
29          go test -race -covermode=atomic -coverprofile='coverage.txt' ./...
30
31      - uses: codecov/codecov-action@v7
32        with:
33          file: ./coverage.txt
34          token: ${{ secrets.CODECOV_TOKEN }}