Protobuf generation #1001
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: Protobuf generation | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
schedule: | |
- cron: "0 0 * * *" | |
jobs: | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Install protobuf | |
uses: arduino/setup-protoc@v1 | |
with: | |
version: '3.x' | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Set up Go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: '1.x' | |
id: go | |
- name: Install protoc-gen-go | |
run: | | |
go install google.golang.org/protobuf/cmd/protoc-gen-go@latest | |
go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest | |
- name: Install goimports | |
run: | | |
go install golang.org/x/tools/cmd/goimports@latest | |
- name: Install proto_generator | |
run: | | |
go install github.com/openconfig/ygot/proto_generator@latest | |
- name: Check out code | |
uses: actions/checkout@v2 | |
with: | |
path: go/src/github.com/openconfig/gribi | |
- name: Get dependencies | |
run: | | |
go get -v -t -d ./... | |
working-directory: go/src/github.com/openconfig/gribi | |
- name: Generate dependencies | |
run: make generate | |
working-directory: go/src/github.com/openconfig/gribi | |
- name: Check up-to-date | |
run: | | |
make protoupdate_check | |
working-directory: go/src/github.com/openconfig/gribi | |