update maintainer email (#4) #8
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: ci | |
on: | |
push: | |
branches: ["main"] | |
pull_request: | |
branches: ["**"] | |
permissions: | |
contents: "read" | |
jobs: | |
check-code-regeneration: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 | |
- name: Set up go | |
uses: actions/setup-go@fac708d6674e30b6ba41289acaab6d4b75aa0753 # v4.0.1 | |
with: | |
go-version: 1.21 | |
- name: Ensure the code has been properly regenerated with 'make regen' | |
run: | | |
go generate ./... | |
readonly changed_files="$(git diff --stat)" | |
if [[ "${changed_files}" != "" ]]; then | |
echo "Found differences after running 'go generate ./...'" | |
echo "Please run 'go generate ./...' & commit the changed files:" | |
echo "${changed_files}" | |
exit 1 | |
fi | |
tests: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 | |
- name: Set up go | |
uses: actions/setup-go@fac708d6674e30b6ba41289acaab6d4b75aa0753 # v4.0.1 | |
with: | |
go-version: 1.21 | |
- name: Build | |
run: go build -v ./... | |
- name: Test | |
run: go test -v ./... | |
# TODO @dvcorreia: add linting workflow |