self-contained: add go binary to vhd #4
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: check-update-go-binary | |
on: | |
pull_request: | |
paths: | |
- 'pkg/proto/**' | |
- 'pkg/parser/**' | |
jobs: | |
check-go-binary: | |
runs-on: ubuntu-latest | |
env: | |
PARSER_BINARY: pkg/parser/bin/parser | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Checkout master branch | |
uses: actions/checkout@v4 | |
with: | |
ref: 'master' | |
path: 'master' | |
- name: Validate Go binary | |
run: | | |
if [ ! -f "${PARSER_BINARY}" ]; then | |
echo "Error: Go binary has not been generated on current branch. Please run 'make update-contract' to generate the go binary." | |
exit 1 | |
fi | |
if cmp -s "${PARSER_BINARY}" "master/${PARSER_BINARY}"; then | |
echo "Error: Go binary has not been updated on current branch. Please run 'make update-contract' to update the go binary." | |
exit 1 | |
fi |