Browse Source

Don't start server if compilation fails

master
Dylan Baker 3 years ago
parent
commit
944d197945
3 changed files with 9 additions and 3 deletions
  1. 3
    1
      start-debug-mode.sh
  2. 3
    1
      start-profiling.sh
  3. 3
    1
      start-release-mode.sh

+ 3
- 1
start-debug-mode.sh View File

7
 
7
 
8
 wasm-pack build --target web --dev --out-dir www/pkg -- --features "with-measure"
8
 wasm-pack build --target web --dev --out-dir www/pkg -- --features "with-measure"
9
 
9
 
10
-basic-http-server ./www -a 0.0.0.0:4001
10
+if [ $? -eq 0 ]; then
11
+  basic-http-server ./www -a 0.0.0.0:4001
12
+fi

+ 3
- 1
start-profiling.sh View File

6
 
6
 
7
 wasm-pack build --target web --profiling --out-dir www/pkg
7
 wasm-pack build --target web --profiling --out-dir www/pkg
8
 
8
 
9
-basic-http-server ./www -a 0.0.0.0:4001
9
+if [ $? -eq 0 ]; then
10
+  basic-http-server ./www -a 0.0.0.0:4001
11
+fi

+ 3
- 1
start-release-mode.sh View File

6
 
6
 
7
 wasm-pack build --target web --release --out-dir www/pkg
7
 wasm-pack build --target web --release --out-dir www/pkg
8
 
8
 
9
-basic-http-server ./www -a 0.0.0.0:4001
9
+if [ $? -eq 0 ]; then
10
+  basic-http-server ./www -a 0.0.0.0:4001
11
+fi

Loading…
Cancel
Save