lib/templates.js
function generate(tmpl, src, variables) {
        variables = variables || {};
        variables.FILES = {};
        for (var i = 0; i < src.length; i++) {
            var content = JSON.stringify(grunt.file.read(src[i]));
            variables.FILES[src[i]] = content;
        }
        var template = grunt.file.read(tmpl);
        return substitute(template, variables);
    }
function generate(tmpl, src, variables) {
        variables = variables || {};
        variables.FILES = {};
        for (var i = 0; i < src.length; i++) {
            var content = JSON.stringify(grunt.file.read(src[i]));
            variables.FILES[src[i]] = content;
        }
        var template = grunt.file.read(tmpl);
        return substitute(template, variables);
    }
function generate ( tmpl , src , variables ) { variables = variables || { } ; variables . FILES = { } ; for ( var i = 0 ; i < src . length ; i ++ ) { var content = JSON . stringify ( grunt . file . read ( src [ i ] ) ) ; variables . FILES [ src [ i ] ] = content ; } var template = grunt . file . read ( tmpl ) ; return substitute ( template , variables ) ; }
Generate a file based on the template and source files.

@param tmpl Path to the template file.
@param src An array of source files.
@param variables Initial variables as an object.
@return A string with template substitutions made.
Generate a file based on the template and source files .