Skip to content

Commit 46b4796

Browse files
committed
Use nodemon for restart the app only if the .js files of the Node.js app changed
1 parent 67758db commit 46b4796

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
- Git clone the repository [dragonnodejs/angularjs-skeleton](https://github.com/dragonnodejs/angularjs-skeleton.git)
66
- Open terminal, switch to the directory and execute:
77
- npm install
8-
- PORT=%PORT% npm run forever
8+
- PORT=%PORT% npm run nodemon
99
- Open another terminal, switch to the directory and execute:
1010
- npm run watchify
1111
- Git commit/push into the master after changes

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"postinstall": "npm run bower && npm run js",
88
"bower": "./node_modules/bower/bin/bower install",
99
"js": "./node_modules/browserify/bin/cmd.js ./js/app.js -o ./web/js/app.js",
10-
"forever": "./node_modules/forever/bin/forever -w app.js",
10+
"nodemon": "./node_modules/nodemon/bin/nodemon.js --watch app.js --watch modules app.js",
1111
"watchify": "./node_modules/watchify/bin/cmd.js ./js/app.js -o ./web/js/app.js"
1212
},
1313
"dependencies": {
@@ -19,7 +19,7 @@
1919
"throng": "^1.0.0"
2020
},
2121
"devDependencies": {
22-
"forever": "^0.14.1",
22+
"nodemon": "^1.3.7",
2323
"watchify": "^2.3.0"
2424
},
2525
"repository": {

0 commit comments

Comments
 (0)