2023-04-22 23:59:33 +05:30
|
|
|
name: Build Vitepress docs
|
|
|
|
|
|
|
|
on:
|
2023-07-18 21:55:44 +05:30
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
- release/*
|
2023-04-22 23:59:33 +05:30
|
|
|
pull_request:
|
2023-07-02 10:03:31 +05:30
|
|
|
merge_group:
|
2023-04-22 23:59:33 +05:30
|
|
|
|
|
|
|
permissions:
|
|
|
|
contents: read
|
|
|
|
|
|
|
|
jobs:
|
2023-07-02 10:14:35 +05:30
|
|
|
build-docs:
|
2023-04-22 23:59:33 +05:30
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-11-09 12:56:57 +01:00
|
|
|
uses: actions/checkout@v4
|
2023-04-22 23:59:33 +05:30
|
|
|
|
|
|
|
- uses: pnpm/action-setup@v2
|
|
|
|
|
|
|
|
- name: Setup Node.js
|
2023-11-09 12:56:57 +01:00
|
|
|
uses: actions/setup-node@v4
|
2023-04-22 23:59:33 +05:30
|
|
|
with:
|
|
|
|
cache: pnpm
|
2024-01-30 20:44:39 +05:30
|
|
|
node-version-file: '.node-version'
|
2023-04-22 23:59:33 +05:30
|
|
|
|
|
|
|
- name: Install Packages
|
|
|
|
run: pnpm install --frozen-lockfile
|
|
|
|
|
2023-10-27 12:22:14 +03:00
|
|
|
- name: Verify release version
|
2023-07-18 21:55:44 +05:30
|
|
|
if: ${{ github.event_name == 'push' && (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/heads/release')) }}
|
|
|
|
run: pnpm --filter mermaid run docs:verify-version
|
|
|
|
|
2023-04-22 23:59:33 +05:30
|
|
|
- name: Run Build
|
|
|
|
run: pnpm --filter mermaid run docs:build:vitepress
|