<commit_before>module.exports = function(grunt) {

	grunt.registerMultiTask('template', 'Interpolate template files with any data you provide and save the result to another file.', function() {
		// Merge task-specific and/or target-specific options with these defaults:
		var options = this.options({
			'data': {}
		});

		// Iterate over all specified file groups.
		this.files.forEach(function(file) {
			// Concat specified files.
			var src = file.src.filter(function(filePath) {
				// Warn on and remove invalid source files.
				if (!grunt.file.exists(filePath)) {
					grunt.log.warn('Source file `' + filePath + '` not found.');
					return false;
				} else {
					return true;
				}
			}).map(function(filePath) {
				// Read file source.
				return grunt.file.read(filePath);
			}).join('\n');
			var data = typeof options.data == 'function' ?
				options.data() :
				options.data;
			var result = grunt.template.process(src, {
				'data': data
			});<commit_msg>Display warning when no templates are found<commit_after>module.exports = function(grunt) {

	grunt.registerMultiTask('template', 'Interpolate template files with any data you provide and save the result to another file.', function() {
		// Merge task-specific and/or target-specific options with these defaults:
		var options = this.options({
			'data': {}
		});

		// Iterate over all specified file groups.
		this.files.forEach(function(file) {
			// Concat specified files.
			var src = file.src.filter(function(filePath) {
				// Warn on and remove invalid source files.
				if (!grunt.file.exists(filePath)) {
					grunt.log.warn('Source file `' + filePath + '` not found.');
					return false;
				} else {
					return true;
				}
			});
			if (!src.length) {
				grunt.log.warn('Destination `' + file.dest + '` not written because `src` files were empty.');
				return;
			}
			var template = src.map(function(filePath) {
				// Read file source.
				return grunt.file.read(filePath);
			}).join('\n');
			var data = typeof options.data == 'function' ?
				options.data() :
				options.data;
			var result = grunt.template.process(template, {
				'data': data
			});
{'fraction_non_alphanumeric': 0.13847583643122677, 'fraction_numerical': 0.0, 'mean_word_length': 3.0699432892249527, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4466659', 'n_tokens_mistral': 781, 'n_tokens_neox': 650, 'n_words': 184}