Add trigger delivery policy basic operations #601
Workflow file for this run
This file contains 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: Build and Test | |
on: | |
# Run on mainline branches | |
push: | |
branches: | |
- 'master' | |
- 'release-*' | |
# Run on branch/tag creation | |
create: | |
# Run on Pull Requests | |
pull_request: | |
jobs: | |
build: | |
name: Build and Test | |
strategy: | |
matrix: | |
go: [1.21.x, 1.22.x] | |
os: [ubuntu-22.04, macos-latest, windows-latest] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Go ${{ matrix.go }} | |
uses: actions/setup-go@v4 | |
with: | |
go-version: ${{ matrix.go }} | |
id: go | |
- name: Check gofmt | |
run: diff -u <(echo -n) <(gofmt -d .) | |
if: matrix.os != 'windows-latest' | |
- name: Run go vet | |
run: go vet $(go list ./... | grep -v /vendor/) | |
- name: Build | |
run: go build -v . | |
- name: Test | |
run: go test -v -race ./... | |
- name: Upload build artifacts | |
uses: actions/upload-artifact@v3 | |
if: matrix.go == '1.21.x' | |
with: | |
path: astartectl* | |
name: astartectl-snapshot-${{ matrix.os }} |