Merge pull request #1134 from middyjs/release/5.0 #77
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: Publish Website | |
on: | |
workflow_dispatch: | |
push: | |
paths: | |
- 'website/*' | |
branches: | |
- main | |
jobs: | |
website: | |
name: Publish website | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [18.x] | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Set up Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Install dependencies | |
working-directory: website | |
run: | | |
npm ci | |
- name: Build website | |
working-directory: website | |
run: | | |
npm run build | |
- name: Publish website | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./website/build |