doc: add links to atlas-action and atlas-sync-action #103
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: Generate | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
workflow_dispatch: | |
jobs: | |
gen: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-go@v3 | |
with: | |
go-version: 1.19 | |
- uses: actions/cache@v3 | |
with: | |
path: | | |
~/.cache/go-build | |
~/go/pkg/mod | |
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }} | |
restore-keys: | | |
${{ runner.os }}-go- | |
- name: go generate cmd/atlas | |
run: go generate ./... | |
- name: Verify generated files are checked in properly | |
run: | | |
status=$(git status --porcelain | grep -v "go.\(sum\|mod\)" | cat) | |
if [ -n "$status" ]; then | |
echo "you need to run 'go generate ./...' and commit the changes" | |
echo "$status" | |
exit 1 | |
fi |