From fed32607dea1cbe3db24fe6b67ecdc7ceed3c173 Mon Sep 17 00:00:00 2001 From: Sidharth Vinod Date: Sat, 29 Oct 2022 01:14:11 +0530 Subject: [PATCH] chore: Update docs build vitepress command --- .github/gh-pages-publish.yml | 9 +++++---- CONTRIBUTING.md | 2 +- packages/mermaid/package.json | 8 ++++---- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/.github/gh-pages-publish.yml b/.github/gh-pages-publish.yml index be79022e9..ef50a8d00 100644 --- a/.github/gh-pages-publish.yml +++ b/.github/gh-pages-publish.yml @@ -18,12 +18,13 @@ jobs: - name: Install deps run: pnpm install - - name: Install and Build 🔧 # This example project is built using npm and outputs the result to the 'build' folder. Replace with the commands required to build your project, or remove this step entirely if your site is pre-built. + - name: Install and Build 🔧 run: | cd ./packages/mermaid - pnpm docs:bundle + pnpm docs:build:vitepress + - name: Deploy 🚀📕 uses: JamesIves/github-pages-deploy-action@v4.3.3 with: - branch: gh-pages # The branch the action should deploy to. - folder: packages/mermaid/src/docs/.vitepress/dist # The folder the action should deploy. + branch: gh-pages + folder: packages/mermaid/src/vitepress/.vitepress/dist diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 49a9fb351..b3543557f 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -80,7 +80,7 @@ $ pnpm docs:dev You can now build and serve the documentation site: ```sh -$ pnpm docs:bundle +$ pnpm docs:build:vitepress $ pnpm docs:serve ``` diff --git a/packages/mermaid/package.json b/packages/mermaid/package.json index 149806544..4f216ecaf 100644 --- a/packages/mermaid/package.json +++ b/packages/mermaid/package.json @@ -34,10 +34,10 @@ "docs:code": "typedoc --plugin typedoc-plugin-markdown --readme none --githubPages false --hideBreadcrumbs --gitRemote disable --hideInPageTOC --namedAnchors --out src/docs/config/setup --entryPointStrategy expand src/defaultConfig.ts src/config.ts src/mermaidAPI.ts && prettier --write ./src/docs/config/setup", "docs:build": "rimraf ../../docs && pnpm docs:code && ts-node-esm src/docs.mts", "docs:verify": "ts-node-esm src/docs.mts --verify", - "docs:build:vitepress": "rimraf src/vitepress && pnpm docs:code && ts-node-esm src/docs.mts --vitepress", - "docs:dev": "pnpm docs:build:vitepress && vitepress dev src/vitepress", - "docs:bundle": "pnpm docs:build:vitepress && vitepress build src/vitepress", - "docs:serve": "pnpm docs:build:vitepress && vitepress serve src/vitepress", + "docs:pre:vitepress": "rimraf src/vitepress && pnpm docs:code && ts-node-esm src/docs.mts --vitepress", + "docs:build:vitepress": "pnpm docs:pre:vitepress && vitepress build src/vitepress", + "docs:dev": "pnpm docs:pre:vitepress && vitepress dev src/vitepress", + "docs:serve": "pnpm docs:pre:vitepress && vitepress serve src/vitepress", "release": "pnpm build", "lint": "eslint --cache --ignore-path .gitignore . && pnpm lint:jison && prettier --check .", "lint:fix": "eslint --fix --ignore-path .gitignore . && prettier --write .",