Skip to content

Security fixes, Azure annotation guard, and version command #49

Security fixes, Azure annotation guard, and version command

Security fixes, Azure annotation guard, and version command #49

Workflow file for this run

---
name: Go
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
build_and_test:
name: Build and Test
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
go: ['1.25']
steps:
- name: Check out code
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go }}
- name: Get dependencies
run: go mod download
- name: Go Mod should be tidy
run: |
go mod tidy
diff -u <(echo -n) <(git diff)
- name: Build packages
run: go build -v ./...
- name: Run Tests
run: go test -v $(go list ./... | grep -E -v /cloudbuild)
lint:
name: lint
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4
with:
fetch-depth: '0'
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.25'
- name: golangci-lint
uses: golangci/golangci-lint-action@v9
with:
args: --config=.github/linters/.golangci.yml
linter:
uses: openconfig/common-ci/.github/workflows/linter.yml@v0.2.0