name: Go on: push: paths-ignore: - 'README.md' - 'sq.json' branches: - master pull_request: paths-ignore: - 'README.md' - 'sq.json' branches: - master jobs: build: strategy: matrix: os: [ macos-latest, ubuntu-latest, windows-latest] runs-on: ${{ matrix.os }} steps: - name: Set up Go 1.19 uses: actions/setup-go@v1 with: go-version: 1.19 id: go - name: Check out code into the Go module directory uses: actions/checkout@v2 - name: Cache Go dependencies uses: actions/cache@v2 with: path: ~/go/pkg/mod key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }} restore-keys: | ${{ runner.os }}-go- - name: Get dependencies run: | go get -v -t -d ./... - name: Build run: go build -v . - name: Test run: go test -short -v ./...