简体   繁体   中英

Can you view your compiled/executed grunt.js file?

I realise this might seem like an odd thing to want, but I'd love to see exactly which paths are being output for my sanity.

// configurable paths
var yeomanConfig = {
    docroot: 'docroot/',
    css: this.docroot+'css',
    fonts: this.docroot+'fonts',
    sass: this.docroot+'sass',
    img: this.docroot+'img',
    js: this.docroot+'js',
    app: 'app',
    dist: '<%= yeoman.docroot %>/dist'
};

For example the above I'd like to see what the JS thinks this really is. Or another example:

        jst: {
            files: [
                '<%= yeoman.js %>/templates/*.ejs'
            ],
            tasks: ['jst']
        }

So can you see the final version of the grunt file with variables included and executed?

Running the task with the verbose option ( grunt --verbose ) will log expanded output (usually) including the files to be operated on.

The grunt api docs specify the behavior of grunt.verbose.write.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM