PeerTube/scripts/watch/server.sh

21 lines
474 B
Bash
Raw Normal View History

2018-03-27 10:35:12 +02:00
#!/bin/sh
set -eu
2017-06-11 11:29:03 +02:00
2018-06-06 14:23:40 +02:00
# Copy locales
mkdir -p "./client/dist"
2018-06-08 11:36:50 +02:00
rm -rf "./client/dist/locale"
2019-11-07 15:33:23 +01:00
cp -r "./client/src/locale" "./client/dist/locale"
2018-06-06 14:23:40 +02:00
2018-08-27 16:34:41 +02:00
rm -rf "./dist"
2018-08-27 10:04:07 +02:00
2019-10-22 08:55:05 +02:00
mkdir "./dist"
cp "./tsconfig.json" "./dist"
2019-11-18 10:34:23 +01:00
npm run tsc -- --incremental --sourceMap
cp -r ./server/static ./server/assets ./dist/server
2018-06-07 16:50:33 +02:00
NODE_ENV=test npm run concurrently -- -k \
2019-11-18 10:34:23 +01:00
"npm run nodemon -- --delay 1 --watch ./dist dist/server" \
"npm run tsc -- --incremental --sourceMap --preserveWatchOutput -w"