mermaid/scripts/editor.bash
Sidharth Vinod 258dbf30e0
Merge branch 'next' into pr/Yokozuna59/4751
* next: (70 commits)
  chore: Add comment for `yy`.
  chore: Increase heap size when building
  chore: increase `test-util.ts` converage by returning `undefined`
  chore: add `vitest` imports to `test-util.ts`
  chore: run `pnpm lint:fix`
  create `noErrorsOrAlternatives` parser helper function
  chore: export `InfoModule` from `infoModule.ts`
  docs: Fix link
  Update docs
  fix(pie): align slices and legend orders
  Mermaid version v10.4.0
  unique batches every time, if not repeated tests end up in the same batch
  Added missed .md
  Increase JS heap
  More tests for redirects + prettier
  Fixed redirects inside vitepress, extended tests
  chore: Explain redirect.ts clearly
  docs: Fix npmjs link
  chore: Update editor.bash to build latest version
  chore: Build after clone
  ...
2023-08-28 14:13:20 +05:30

27 lines
555 B
Bash
Executable File

#!/usr/bin/env bash
# Fail on errors
set -euxo pipefail
# Increase heap size
export NODE_OPTIONS="--max_old_space_size=4096"
# Build mermaid
pnpm build
# Clone the Mermaid Live Editor repository
rm -rf mermaid-live-editor
git clone --single-branch https://github.com/mermaid-js/mermaid-live-editor.git
cd mermaid-live-editor
# We have to use npm instead of yarn because it causes trouble in netlify
# Install dependencies
npm install
# Link local mermaid to live editor
npm link ../packages/mermaid
# Force Build the site
npm run build -- --force