diff options
author | Chocobozzz <me@florianbigard.com> | 2020-02-19 09:14:28 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2020-02-19 09:14:28 +0100 |
commit | 99ae9d3a9eeaf3db5c66bde006aded133757cb17 (patch) | |
tree | 523740e445c26edfb3c2aecef39f7c20bb77fe67 /scripts | |
parent | 302cb3f92e2c4e4dc580e24ad15f5d003f16f285 (diff) | |
download | PeerTube-99ae9d3a9eeaf3db5c66bde006aded133757cb17.tar.gz PeerTube-99ae9d3a9eeaf3db5c66bde006aded133757cb17.tar.zst PeerTube-99ae9d3a9eeaf3db5c66bde006aded133757cb17.zip |
Fix npm run dev
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/dev/client.sh | 2 | ||||
-rwxr-xr-x | scripts/dev/index.sh | 2 | ||||
-rwxr-xr-x | scripts/dev/server.sh | 6 |
3 files changed, 6 insertions, 4 deletions
diff --git a/scripts/dev/client.sh b/scripts/dev/client.sh index a056b7d7f..e9cade800 100755 --- a/scripts/dev/client.sh +++ b/scripts/dev/client.sh | |||
@@ -5,7 +5,7 @@ set -eu | |||
5 | clientCommand="cd client && node node_modules/.bin/ng serve --proxy-config proxy.config.json --hmr --configuration hmr --host 0.0.0.0 --disable-host-check --port 3000" | 5 | clientCommand="cd client && node node_modules/.bin/ng serve --proxy-config proxy.config.json --hmr --configuration hmr --host 0.0.0.0 --disable-host-check --port 3000" |
6 | serverCommand="npm run build:server && NODE_ENV=test node dist/server" | 6 | serverCommand="npm run build:server && NODE_ENV=test node dist/server" |
7 | 7 | ||
8 | if [ ! -z ${1+x} ] && [ "$1" == "--skip-server" ]; then | 8 | if [ ! -z ${1+x} ] && [ "$1" = "--skip-server" ]; then |
9 | NODE_ENV=test eval $clientCommand | 9 | NODE_ENV=test eval $clientCommand |
10 | else | 10 | else |
11 | NODE_ENV=test node node_modules/.bin/concurrently -k \ | 11 | NODE_ENV=test node node_modules/.bin/concurrently -k \ |
diff --git a/scripts/dev/index.sh b/scripts/dev/index.sh index 218d02b8c..56addb7fe 100755 --- a/scripts/dev/index.sh +++ b/scripts/dev/index.sh | |||
@@ -4,4 +4,4 @@ set -eu | |||
4 | 4 | ||
5 | NODE_ENV=test npm run concurrently -- -k \ | 5 | NODE_ENV=test npm run concurrently -- -k \ |
6 | "sh scripts/dev/client.sh --skip-server" \ | 6 | "sh scripts/dev/client.sh --skip-server" \ |
7 | "sh scripts/dev/server.sh" | 7 | "sh scripts/dev/server.sh --skip-client" |
diff --git a/scripts/dev/server.sh b/scripts/dev/server.sh index 187a1843e..680ca3d79 100755 --- a/scripts/dev/server.sh +++ b/scripts/dev/server.sh | |||
@@ -3,8 +3,10 @@ | |||
3 | set -eu | 3 | set -eu |
4 | 4 | ||
5 | if [ ! -f "./client/dist/en-US/index.html" ]; then | 5 | if [ ! -f "./client/dist/en-US/index.html" ]; then |
6 | echo "client/dist/en-US/index.html does not exist, compile client files..." | 6 | if [ -z ${1+x} ] || [ "$1" != "--skip-client" ]; then |
7 | npm run build:client -- --light | 7 | echo "client/dist/en-US/index.html does not exist, compile client files..." |
8 | npm run build:client -- --light | ||
9 | fi | ||
8 | fi | 10 | fi |
9 | 11 | ||
10 | # Copy locales | 12 | # Copy locales |