Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions build-dashboard.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,17 @@ set -e
# re-evaluated from inside dashboard/.
ROOT="$(cd "$(dirname "$0")" && pwd)"
cd "$ROOT/dashboard"

# A fresh clone has no node_modules, so `npm run build` dies with
# "vite: not recognized" before anything is built. Install first.
if [ ! -x node_modules/.bin/vite ]; then
if [ -f package-lock.json ]; then
npm ci
else
npm install
fi
fi

npm run build

ASSETS="$ROOT/the_lab/static/assets"
Expand Down