xlate 0.4.0 - initial public release #1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: ci | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| permissions: | |
| contents: read | |
| jobs: | |
| test: | |
| name: build & test | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version-file: go.mod | |
| check-latest: true | |
| - name: gofmt | |
| run: | | |
| out="$(gofmt -l .)" | |
| if [ -n "$out" ]; then echo "gofmt required:"; echo "$out"; exit 1; fi | |
| - name: go vet | |
| run: go vet ./... | |
| - name: build | |
| run: go build ./... | |
| - name: unit, validation and regression tests (race detector) | |
| run: go test -race -count=1 ./... | |
| - name: end-to-end tests | |
| run: go test -tags e2e -count=1 -timeout 10m ./... | |
| - name: coverage | |
| run: | | |
| go test -covermode=atomic -coverprofile=cover.out ./... | |
| go tool cover -func=cover.out | tail -n 1 | |
| lint: | |
| name: staticcheck | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version-file: go.mod | |
| check-latest: true | |
| - run: go install honnef.co/go/tools/cmd/staticcheck@latest | |
| - run: staticcheck -checks=all ./... | |
| vuln: | |
| name: govulncheck | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version-file: go.mod | |
| check-latest: true | |
| - run: go install golang.org/x/vuln/cmd/govulncheck@latest | |
| - run: govulncheck ./... |