-
Notifications
You must be signed in to change notification settings - Fork 0
/
Gruntfile.js
88 lines (81 loc) · 2.21 KB
/
Gruntfile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
module.exports = function(grunt) {
grunt.initConfig({
watch: {
css: {
files: ['dist/1.2/sass/**/*.scss'],
tasks: ['sass_globbing', 'sass'],
options: {
spawn: false
}
}
},
sass: {
dist: {
options: {
style: 'expanded'
},
files: {
'dist/1.2/css/geo-framework.css': 'src/1.2/sass/geo-framework.scss'
}
}
},
sass_globbing: {
your_target: {
files: {
'src/1.2/sass/helpers.scss': 'src/1.2/sass/helpers/*.scss',
'src/1.2/sass/bosons.scss': 'src/1.2/sass/bosons/*.scss',
'src/1.2/sass/atoms.scss': 'src/1.2/sass/atoms/*.scss',
'src/1.2/sass/molecules.scss': 'src/1.2/sass/molecules/*.scss',
'src/1.2/sass/organisms.scss': 'src/1.2/sass/organisms/*.scss',
},
options: {
useSingleQuotes: false
}
}
},
clean: {
build: {
src: ['dist/1.2/**']
}
},
cssmin: {
all: {
src: [
'dist/1.2/css/geo-framework.css'
],
dest: 'dist/1.2/css/geo-framework.min.css'
}
},
concat: {
core: {
src: ['src/1.2/js/core/*.js'],
dest: 'dist/1.2/js/geo-framework-core.js'
},
plugins: {
src: ['src/js/plugins/*.js'],
dest: 'dist/1.2/js/geo-framework-plugins.js'
},
vendors: {
src: ['src/1.2/js/vendors/*.js'],
dest: 'dist/1.2/js/geo-framework-vendors.js'
}
},
uglify: {
js: {
files: {
'dist/1.2/js/geo-framework.min.js': ['dist/1.2/js/geo-framework-core.js', 'dist/1.2/js/geo-framework-plugins.js', 'dist/1.2/js/geo-framework-vendors.js']
}
}
}
});
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-contrib-sass');
grunt.loadNpmTasks('grunt-contrib-clean');
grunt.loadNpmTasks('grunt-contrib-copy');
grunt.loadNpmTasks('grunt-contrib-cssmin');
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-sass-globbing');
grunt.registerTask('dev', ['sass_globbing', 'sass', 'watch']);
grunt.registerTask('build', ['clean', 'cssmin', 'concat', 'uglify']);
};