b01d783a by Adam Heath

Start working on renaming files based on their hash.; WORKS!

1 parent ddded37c
...@@ -39,7 +39,16 @@ module.exports = function (grunt) { ...@@ -39,7 +39,16 @@ module.exports = function (grunt) {
39 }] 39 }]
40 }, 40 },
41 }, 41 },
42 }; 42 rev: {
43 css: {
44 files: {
45 src: _.map(common.css.options.dirs, function (value) {
46 return 'dist/' + value + '/{,**/}*.css';
47 }),
48 }
49 },
50 },
51 };
43 var checkList = []; 52 var checkList = [];
44 var buildList = [ 53 var buildList = [
45 'check', 54 'check',
...@@ -213,6 +222,9 @@ module.exports = function (grunt) { ...@@ -213,6 +222,9 @@ module.exports = function (grunt) {
213 }] 222 }]
214 }; 223 };
215 initConfig.clean.dist.files[0].src.push('.grunt/usemin-css'); 224 initConfig.clean.dist.files[0].src.push('.grunt/usemin-css');
225 initConfig.usemin.css = _.map(common.css.options.dirs, function (value) {
226 return 'dist/' + value + '/{,**/}*.css';
227 });
216 228
217 buildList.push('useminPrepare'); // html 229 buildList.push('useminPrepare'); // html
218 //buildList.push('usemin:views' 230 //buildList.push('usemin:views'
...@@ -230,7 +242,7 @@ module.exports = function (grunt) { ...@@ -230,7 +242,7 @@ module.exports = function (grunt) {
230 //'modernizr'); 242 //'modernizr');
231 //buildList.push('uglify:generated'); // montyPython 243 //buildList.push('uglify:generated'); // montyPython
232 //'rev:dist'); // montyPython 244 //'rev:dist'); // montyPython
233 //buildList.push('rev:css'); // montyPython 245 buildList.push('rev:css'); // montyPython
234 //buildList.push('revconfig'); // montyPython 246 //buildList.push('revconfig'); // montyPython
235 //buildList.push('uglify:bower'); // montyPython 247 //buildList.push('uglify:bower'); // montyPython
236 //buildList.push('uglify:requireconfig'); // montyPython 248 //buildList.push('uglify:requireconfig'); // montyPython
......
...@@ -23,6 +23,7 @@ ...@@ -23,6 +23,7 @@
23 "grunt-contrib-cssmin": "~0.12.3", 23 "grunt-contrib-cssmin": "~0.12.3",
24 "grunt-contrib-jshint": "~0", 24 "grunt-contrib-jshint": "~0",
25 "grunt-contrib-htmlmin": "~0", 25 "grunt-contrib-htmlmin": "~0",
26 "grunt-rev": "~0",
26 "grunt-usemin": "~2", 27 "grunt-usemin": "~2",
27 "lodash": "~2", 28 "lodash": "~2",
28 "punch": "~0.5.46", 29 "punch": "~0.5.46",
......