Skip to content

GitHub Actions: use actions/deploy-pages #99

GitHub Actions: use actions/deploy-pages

GitHub Actions: use actions/deploy-pages #99

Workflow file for this run

name: Node CI
on:
push:
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '20'
- run: yarn install --no-progress --frozen-lockfile
- run: yarn test
- run: yarn build
- uses: actions/configure-pages@v3
- uses: actions/upload-pages-artifact@v2
with:
path: ./dist
deploy:
runs-on: ubuntu-latest
if: github.event_name == 'workflow_dispatch' || (github.event_name == 'push' && github.ref == 'refs/heads/master')
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: 'pages'
cancel-in-progress: true
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2