From c0e4eaae9ee8bf23a3ef45852eaf008b211bdc66 Mon Sep 17 00:00:00 2001 From: Remy Sharp Date: Wed, 17 Jul 2019 14:56:58 +0100 Subject: [PATCH] fix: langauge around "watching" ref: #1583 It was unclear whether it was listing files being watched when in fact it was the list of directories (plus, make it cleaner) --- lib/nodemon.js | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/lib/nodemon.js b/lib/nodemon.js index 1020f22..042da84 100644 --- a/lib/nodemon.js +++ b/lib/nodemon.js @@ -180,8 +180,16 @@ function nodemon(settings) { }).filter(Boolean).join(' '); if (ignoring) utils.log.detail('ignoring: ' + ignoring); - utils.log.info('watching: ' + config.options.monitor.map(function (rule) { - return rule.slice(0, 1) !== '!' ? rule : false; + utils.log.info('watching dir(s): ' + config.options.monitor.map(function (rule) { + if (rule.slice(0, 1) !== '!') { + try { + rule = path.relative(process.cwd(), rule); + } catch (e) {} + + return rule; + } + + return false; }).filter(Boolean).join(' ')); utils.log.detail('watching extensions: ' + (config.options.execOptions.ext || '(all)'));