Fix homebrew release #17
Workflow file for this run
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: Go Code Generation Check | |
on: | |
pull_request: | |
branches: | |
- main | |
workflow_dispatch: | |
jobs: | |
generate: | |
name: Check Code Generation | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Set up Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: '1.22' | |
- name: Set up Go bin in PATH | |
run: echo "${HOME}/go/bin" >> $GITHUB_PATH | |
- name: Install Dependencies and Tools | |
run: | | |
make install-deps install-abigen install-mockgen | |
- name: Generate Code | |
run: make generate | |
- name: Check for Uncommitted Changes | |
run: | | |
if [[ $(git status --porcelain) ]]; then | |
echo '::error::Uncommitted changes detected. Please run `make generate` and commit the generated code.' | |
echo 'Modified files:' | |
git status --porcelain | |
exit 1 | |
else | |
echo 'No uncommitted changes. All generated code is up to date.' | |
fi |