sync: sync master to develop #2570
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
# Protobuf files lint and backwards compatibility check job | |
# reference: <https://docs.buf.build/ci-cd/github-actions> | |
name: protobuf-check | |
on: | |
push: | |
branches: | |
- master | |
- develop | |
pull_request: | |
branches: | |
- master | |
- develop | |
jobs: | |
protobuf-check: | |
strategy: | |
matrix: | |
go-version: [1.20.x] | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: bufbuild/[email protected] | |
- run: buf format --diff --exit-code | |
- name: Install Go | |
uses: actions/setup-go@v3 | |
with: | |
go-version: ${{ matrix.go-version }} | |
- name: Test protobuf changes generates new go files | |
run: | | |
export PATH="$PATH:$(go env GOPATH)/bin" | |
go mod tidy | |
make tools proto-gen-check | |
- name: Test protobuf swagger changes | |
run: | | |
export PATH="$PATH:$(go env GOPATH)/bin" | |
make tools proto-swagger-check |