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
|
|
|
|
2024-08-24 15:04:14 +05:30
|
|
|
concurrency: ${{ github.workflow }}-${{ github.ref }}
|
|
|
|
|
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
|
2024-08-24 09:26:49 +00:00
|
|
|
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
|
2023-04-22 23:59:33 +05:30
|
|
|
|
2024-08-24 09:26:49 +00:00
|
|
|
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
|
2023-04-22 23:59:33 +05:30
|
|
|
|
|
|
|
- name: Setup Node.js
|
2024-08-24 09:26:49 +00:00
|
|
|
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
|
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
|