diff options
author | liabru <liabru@brm.io> | 2015-11-09 23:54:52 +0000 |
---|---|---|
committer | liabru <liabru@brm.io> | 2015-11-09 23:54:52 +0000 |
commit | 9e6487d08ac96ecd0ccdebb4b6d8051b4fc062fb (patch) | |
tree | 0682f6aa0c558a4f6a7a552fc6f75b1980acb218 | |
parent | dc9716b0385ea1c20bd81b7ca84e82f6caa92cd1 (diff) | |
download | jquery-match-height-9e6487d08ac96ecd0ccdebb4b6d8051b4fc062fb.zip jquery-match-height-9e6487d08ac96ecd0ccdebb4b6d8051b4fc062fb.tar.gz jquery-match-height-9e6487d08ac96ecd0ccdebb4b6d8051b4fc062fb.tar.bz2 |
handle error when test server is already running
-rw-r--r-- | gulpfile.js | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/gulpfile.js b/gulpfile.js index 6ee1d74..e411bea 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -71,6 +71,12 @@ gulp.task('changelog', function () { }); gulp.task('serve', function() { + process.on('uncaughtException', function(err) { + if (err.errno === 'EADDRINUSE') { + console.log('Server already running (or port is otherwise in use)'); + } + }); + server = gulp.src('.') .pipe(webserver({ host: '0.0.0.0', |