Skip to content

Commit

Permalink
ci: deploy docs
Browse files Browse the repository at this point in the history
  • Loading branch information
octoshikari committed Jul 20, 2023
1 parent b2f808f commit 094058e
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/doc.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Deploy docs

on:
push:
branches:
- main

jobs:
deploy:
runs-on: ubuntu-latest
defaults:
run:
working-directory: "doc" # Here the path to the folder where package-lock.json is located.
steps:
- name: Checkout sources
uses: actions/checkout@v3

- name: Setup pnpm
uses: pnpm/action-setup@v2
with:
version: 8
run_install: false

- name: Use Node.js 18
uses: actions/setup-node@v3
with:
node-version: 18
cache: pnpm
cache-dependency-path: ./doc/pnpm-lock.yaml

- name: Install dependencies
working-directory: "doc"
run: pnpm install --frozen-lockfile

- name: Build
working-directory: "doc"
run: pnpm build

- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: doc/doc/.vitepress/dist

0 comments on commit 094058e

Please sign in to comment.