Limit contributers display. Fixes #13
[roll.divinelegy.git] / Gruntfile.js
1 module.exports = function (grunt) {
2
3 grunt.initConfig({
4 pkg: grunt.file.readJSON('package.json'),
5
6 clean: {
7 dist: {
8 force:true,
9 src: ["dist", '.tmp']
10 }
11 },
12
13 copy: {
14 main: {
15 expand: true,
16 cwd: 'app/',
17 src: ['**', '!**/*/*.html', '!js/**', '!lib/**', '!**/*.example', '!**/*.css', '!**/*.js', '!**/bower_components/**', '!**/nbproject/**', '!**/font-awesome/**', '!npm-debug.log'],
18 dest: 'dist/'
19 },
20 fa: {
21 expand: true,
22 cwd: 'app/css/font-awesome',
23 src: ['fonts/**'],
24 dest: 'dist/'
25 },
26 shims: {
27 expand: true,
28 cwd: 'app/lib/webshim/shims',
29 src: ['**'],
30 dest: 'dist/js/shims'
31 }
32 },
33
34 replace: {
35 DivinElegy: {
36 src: ['dist/js/divinelegy.min.js'],
37 overwrite: true,
38 replacements: [{
39 from: /value\(\"rockEndpoint\",[^\)]*\)/g,
40 to: 'value("rockEndpoint", "http://rock.divinelegy.com/")'
41 }]
42 }
43 },
44
45 cleanempty: {
46 options: {},
47 src: ['dist/**']
48 },
49
50 rev: {
51 files: {
52 src: ['dist/**/*.{js,css}', '!dist/js/shims/**']
53 }
54 },
55
56 useminPrepare: {
57 html: 'app/index.html'
58 },
59
60 usemin: {
61 html: ['dist/index.html']
62 },
63
64 uglify: {
65 options: {
66 report: 'min',
67 mangle: true
68 }
69 },
70
71 ngtemplates: {
72 DivinElegy: {
73 cwd: 'app',
74 src: ['**/*.html', '!index.html'],
75 dest: '.tmp/templates.js',
76 options: {
77 base: 'dist',
78 module: 'DivinElegy',
79 usemin: 'js/divinelegy.min.js',
80 htmlmin: {
81 collapseBooleanAttributes: true,
82 collapseWhitespace: true,
83 conservativeCollapse: true,
84 removeAttributeQuotes: true,
85 removeComments: true, // Only if you don't use comment directives!
86 removeEmptyAttributes: true,
87 removeRedundantAttributes: false, //if this is on input="text" is stripped and some selectors fail
88 removeScriptTypeAttributes: true,
89 removeStyleLinkTypeAttributes: true
90 }
91 }
92 }
93 }
94 });
95
96 grunt.loadNpmTasks('grunt-contrib-clean');
97 grunt.loadNpmTasks('grunt-contrib-copy');
98 grunt.loadNpmTasks('grunt-contrib-concat');
99 grunt.loadNpmTasks('grunt-contrib-cssmin');
100 grunt.loadNpmTasks('grunt-contrib-uglify');
101 grunt.loadNpmTasks('grunt-rev');
102 grunt.loadNpmTasks('grunt-usemin');
103 grunt.loadNpmTasks('grunt-cleanempty');
104 grunt.loadNpmTasks('grunt-angular-templates');
105 grunt.loadNpmTasks('grunt-text-replace');
106
107 // Tell Grunt what to do when we type "grunt" into the terminal
108 grunt.registerTask('default', [
109 'clean',
110 'copy',
111 'cleanempty',
112 'useminPrepare',
113 'ngtemplates',
114 'concat',
115 'uglify',
116 'cssmin',
117 'usemin',
118 'replace'
119 ]);
120 };