Generator: Add optional index to condition for matching bitmaps #62
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: | |
pull_request: | |
paths-ignore: | |
- 'README.md' | |
- 'LICENSE' | |
branches: | |
- master | |
push: | |
paths-ignore: | |
- 'README.md' | |
- 'LICENSE' | |
branches: | |
- master | |
jobs: | |
generate_and_test: | |
name: Generate and test ZCL | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
path: zcl | |
- uses: actions/checkout@v3 | |
with: | |
repository: hemtjanst/zyaml | |
path: zyaml | |
- uses: actions/setup-go@v4 | |
with: | |
go-version: 'stable' | |
check-latest: true | |
- name: Generate ZCL | |
working-directory: ./zcl | |
run: | | |
go run hemtjan.st/zcl/cmd/zclgen -definition-path ../zyaml | |
if test -n "$(git status -s)"; then | |
echo "Repository is in dirty state!" | |
echo " Update your copy of zyaml to latest master" | |
echo " Regenerate using cmd/zclgen" | |
echo "Changed files:" | |
git status -s | |
exit 1 | |
fi | |
- name: Build updated ZCL | |
working-directory: ./zcl | |
run: | | |
go build hemtjan.st/zcl/... | |
- name: Run ZCL tests | |
working-directory: ./zcl | |
run: | | |
go test -v hemtjan.st/zcl/... |