Skip to content

Deploy to GitHub Pages #17

Deploy to GitHub Pages

Deploy to GitHub Pages #17

Workflow file for this run

name: Deploy to GitHub Pages
permissions:
contents: write
on:
workflow_dispatch:
inputs:
branch:
type: choice
description: Which branch to deploy to GH Pages?
required: true
options:
- main
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.event.inputs.branch }}
- name: Install pnpm
run: corepack enable
- name: Use Node.js 22.x
uses: actions/setup-node@v4
with:
node-version: 22.x
cache: pnpm
- name: Install dependencies
run: pnpm install -r
- name: Build
run: npm run build
- name: Build docs
run: npm run docs
- name: Deploy
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs
publish_branch: gh-pages
destination_dir: docs