Reset blocks variable when importing stacks #14
Workflow file for this run
This file contains hidden or 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: Build assets | |
| on: | |
| pull_request: | |
| push: | |
| branches: | |
| - main | |
| - master | |
| tags-ignore: | |
| - '**' | |
| jobs: | |
| build-assets: | |
| name: Build assets | |
| runs-on: ubuntu-latest | |
| steps: | |
| - | |
| name: Checkout | |
| uses: actions/checkout@v4 | |
| - | |
| name: Install NodeJS | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: npm | |
| - | |
| name: Install dependencies | |
| run: npm ci | |
| - | |
| name: Build | |
| run: npm run-script production | |
| - | |
| name: Check changes | |
| id: check-changes | |
| run: | | |
| if git diff --exit-code --quiet assets; then | |
| echo 'No changes detected.' | |
| else | |
| echo 'Changes detected!' | |
| run: echo "CHANGES=yes" >>"$GITHUB_OUTPUT" | |
| fi | |
| - | |
| name: Commit changes | |
| if: steps.check-changes.outputs.CHANGES == 'yes' && github.event_name == 'push' && (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/master') | |
| run: | | |
| git config user.name "GitHub Actions" | |
| git config user.email noreply@github.com | |
| git add assets | |
| git commit -m "Build assets" | |
| git push |