Bump husky from 9.0.11 to 9.1.1 #154
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: Code generation and cleanup on pull | |
on: | |
pull_request: | |
branches: | |
- main | |
jobs: | |
generate-and-commit-code: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
repository: ${{ github.event.pull_request.head.repo.full_name }} | |
ref: ${{ github.event.pull_request.head.ref }} | |
token: ${{ secrets.ACTION_COMMIT }} | |
- name: Cache go dependencies | |
uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cache/go-build | |
~/go/pkg/mod | |
key: go_dependencies-${{ hashFiles('go.sum', 'go.work.sum') }} | |
restore-keys: | | |
go_dependencies-${{ hashFiles('go.sum', 'go.work.sum') }} | |
go_dependencies- | |
- name: Cache node modules | |
uses: actions/cache@v4 | |
with: | |
path: node_modules | |
key: node_modules-${{hashFiles('package-lock.json')}} | |
restore-keys: | | |
node_modules-${{hashFiles('package-lock.json')}} | |
node_modules- | |
- name: Cache elm dependencies | |
uses: actions/cache@v4 | |
with: | |
path: | | |
~/.elm | |
elm-stuff | |
key: "elm-dependencies-\ | |
${{hashFiles('elm.json', 'review/elm.json')}}" | |
restore-keys: | | |
elm-dependencies-${{hashFiles('elm.json', 'review/elm.json')}} | |
elm-dependencies- | |
- name: Set up Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: "1.22" | |
cache: false | |
- name: Set up Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 21.x | |
cache: "npm" | |
- name: Create empty file in webroot | |
run: mkdir -p webroot && touch webroot/empty | |
- name: Install go dependencies | |
run: go install | |
- name: Install npm dependencies | |
run: npm ci | |
- name: Run generate | |
run: npm run generate | |
- name: Run cleanup | |
run: npm run cleanup | |
- name: Run tests | |
run: npm run test | |
- name: Build project | |
run: npm run build | |
- name: Run cleanup | |
run: npm run cleanup | |
- name: Commit and Push Generated Code | |
run: | | |
git config --local user.email "[email protected]" | |
git config --local user.name "GitHub Action" | |
git add . | |
git commit -m "Update generated code and cleanup" -a || echo "No changes to commit" | |
git push |