mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-09-17 22:39:56 +02:00
build: change mermaid live preview to use pnpm
Right now, the netlify build seems to be failing since we're ignoring the `mermaid-live-editor` lockfile. This is causing errors with broken dependencies. Switching to `pnpm`, which the `mermaid-live-editor` uses, fixes these issues!
This commit is contained in:
@@ -11,7 +11,6 @@ pushd packages/mermaid
|
|||||||
# Append commit hash to version
|
# Append commit hash to version
|
||||||
jq ".version = .version + \"+${COMMIT_REF:0:7}\"" package.json > package.tmp.json
|
jq ".version = .version + \"+${COMMIT_REF:0:7}\"" package.json > package.tmp.json
|
||||||
mv package.tmp.json package.json
|
mv package.tmp.json package.json
|
||||||
yarn link
|
|
||||||
popd
|
popd
|
||||||
|
|
||||||
pnpm run -r clean
|
pnpm run -r clean
|
||||||
@@ -26,13 +25,14 @@ cd mermaid-live-editor
|
|||||||
git clean -xdf
|
git clean -xdf
|
||||||
rm -rf docs/
|
rm -rf docs/
|
||||||
|
|
||||||
# We have to use npm instead of yarn because it causes trouble in netlify
|
# Tells PNPM that mermaid-live-editor is not part of this workspace
|
||||||
|
touch pnpm-workspace.yaml
|
||||||
|
|
||||||
# Install dependencies
|
# Install dependencies
|
||||||
yarn install
|
pnpm install --frozen-lockfile
|
||||||
|
|
||||||
# Link local mermaid to live editor
|
# Link local mermaid to live editor
|
||||||
yarn link mermaid
|
pnpm link ../packages/mermaid
|
||||||
|
|
||||||
# Force Build the site
|
# Force Build the site
|
||||||
yarn run build
|
pnpm run build
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user