How not to guess already a miniature on each "grunt assembly" in yomanka
uglify: { onlyScripts: { files: [{ dest: '<%= yeoman.dist %>/scripts/scripts.js', src: ['.tmp/concat/scripts/scripts.js'] }] } }
In addition, now uglify will not copy your vendor.js from a temporary folder, so add the "vendorJS" section to "copy" the task:
copy: //... vendorJS: { expand: true, cwd: '.tmp/concat/scripts/', dest: '<%= yeoman.dist %>/scripts/', src: 'vendor.js' }
Then, in the "build" task, set the uglify parameter to "onlyScripts" and copy the vendor.js file:
grunt.registerTask('build', [ 'jshint', 'clean:dist', //'wiredep', // ... 'useminPrepare', //'concurrent:dist', 'autoprefixer', 'concat', 'ngAnnotate', 'copy:dist', 'cssmin', 'uglify:onlyScripts', 'copy:vendorJS', // ... ]);
http://eugenioz.blogspot.in/2014/08/how-to-not-minify-already-minified-on.html
Priyanshu Chauhan
source share