refactor: update github action script #34
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: Web API tutorial CI | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
page-generator: | |
name: Generating pages | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
persist-credentials: false | |
- name: Setup Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 'latest' | |
- name: Install dependencies | |
run: npm install | |
- name: Build pages | |
run: npm run build | |
- name: Deploy to website | |
uses: JamesIves/github-pages-deploy-action@v4 | |
with: | |
git-config-name: wangdoc-bot | |
git-config-email: [email protected] | |
repository-name: wangdoc/website | |
token: ${{ secrets.WANGDOC_BOT_TOKEN }} | |
branch: master # The branch the action should deploy to. | |
folder: dist # The folder the action should deploy. | |
target-folder: dist/webapi | |
clean: true # Automatically remove deleted files from the deploy branch | |
commit-message: update from WebAPI tutorial | |