From ff6cd0435e2102526e058270036bace6ce105db5 Mon Sep 17 00:00:00 2001 From: paladox Date: Fri, 25 Mar 2016 20:42:57 +0000 Subject: [PATCH] Add new option log The default is set as true. This is so a user has a choice between verbose or just seeing that the file has been created and dosent't want to see all the information. Follows up https://github.com/gruntjs/grunt-contrib-concat/pull/145/files And fixes https://github.com/gruntjs/grunt-contrib-concat/issues/153 --- tasks/concat.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/tasks/concat.js b/tasks/concat.js index 81fd862..5155282 100644 --- a/tasks/concat.js +++ b/tasks/concat.js @@ -21,6 +21,7 @@ module.exports = function(grunt) { separator: grunt.util.linefeed, banner: '', footer: '', + log: true, stripBanners: false, process: false, sourceMap: false, @@ -114,7 +115,12 @@ module.exports = function(grunt) { grunt.file.write(f.dest, src); // Print a success message. - grunt.verbose.write('File ' + chalk.cyan(f.dest) + ' created.'); + if (options.log === true) { + grunt.log.writeln('File ' + chalk.cyan(f.dest) + ' created.'); + } else { + grunt.verbose.write('File ' + chalk.cyan(f.dest) + ' created.'); + } + } }); });