Merge pull request #252 from dan-mba/dependabot/npm_and_yarn/types/js… #280
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: Build | |
on: | |
workflow_dispatch: | |
push: | |
branches: [ main ] | |
paths: | |
- "**.js" | |
- "**.ts" | |
- "**.json" | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 'lts/*' | |
- name: Build | |
run: | | |
rm -rf dist | |
npm ci | |
npm run build | |
- name: Commit files | |
run: | | |
git config --local user.email "action@github.com" | |
git config --local user.name "GitHub Action" | |
git add -A dist | |
git diff-index --quiet --cached HEAD || git commit -m "Build Action" | |
- name: Push changes | |
uses: ad-m/github-push-action@master | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} |