File tree Expand file tree Collapse file tree 2 files changed +16
-1
lines changed Expand file tree Collapse file tree 2 files changed +16
-1
lines changed Original file line number Diff line number Diff line change 44 "description" : " A nuclearjs test" ,
55 "main" : " client/index.js" ,
66 "scripts" : {
7- "test" : " echo \" Error: no test specified\" && exit 1"
7+ "test" : " echo \" Error: no test specified\" && exit 1" ,
8+ "build" : " $(npm bin)/webpack" ,
9+ "run" : " sh run.sh"
810 },
911 "author" :
" Diego Gadola <[email protected] >" ,
1012 "license" : " ISC" ,
2022 "css-loader" : " ^0.15.1" ,
2123 "file-loader" : " ^0.8.4" ,
2224 "jquery" : " ^2.1.4" ,
25+ "json-server" : " ^0.7.25" ,
2326 "node-libs-browser" : " ^0.5.2" ,
2427 "node-sass" : " ^3.2.0" ,
2528 "nuclear-js" : " ^1.0.5" ,
Original file line number Diff line number Diff line change 1+ echo ' Starting contacts API ...'
2+ $( npm bin) /json-server -w db.json & > /dev/null &
3+ export JS_PID=$!
4+ echo ' API started'
5+ echo ' Starting frontend server ...'
6+ cd build
7+ python -m SimpleHTTPServer & > /dev/null &
8+ export HTTP_PID=$!
9+ echo ' frontend started'
10+ trap ' kill -2 $JS_PID && kill -9 $HTTP_PID && echo API and frontend stopped.' SIGINT
11+ trap ' kill -9 $JS_PID && kill -9 $HTTP_PID && echo API and frontend stopped.' SIGKILL
12+ wait
You can’t perform that action at this time.
0 commit comments