This repository has been archived by the owner on Sep 5, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgruntfile.js
77 lines (77 loc) · 2.86 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
module.exports = function(grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
cssmin: {
target: {
files: [
{'www/css/cssui.min.css': [
'node_modules/normalize.css/normalize.css',
'node_modules/open-sans-fontface/open-sans.css',
'node_modules/font-awesome/css/font-awesome.css',
'node_modules/perfect-scrollbar/css/perfect-scrollbar.css',
'node_modules/css-ui-simple/css/cssui.css',
'node_modules/css-ui-responsive-menu/css/style.menu.css',
'node_modules/css-ui-dropdown-menu/css/style.dropdown.css',
'node_modules/css-ui-tooltip/css/style.tooltip.css',
'node_modules/css-ui-tooltip/css/style.tooltip.theme.css',
'node_modules/css-ui-table/css/style.tables.css',
'node_modules/css-ui-modal-box/css/style.modal.box.css'
]},
{'www/css/cssui-menu-light.min.css': [
'node_modules/css-ui-responsive-menu/css/style.menu.light.css'
]},
{'www/css/cssui-menu-dark.min.css': [
'node_modules/css-ui-responsive-menu/css/style.menu.dark.css'
]},
{'www/css/cssui-dropdown-light.min.css': [
'node_modules/css-ui-dropdown-menu/css/style.dropdown.light.css'
]},
{'www/css/cssui-dropdown-dark.min.css': [
'node_modules/css-ui-dropdown-menu/css/style.dropdown.dark.css'
]},
{'www/css/cssui-login.min.css': [
'node_modules/css-ui-sign-in/css/style.sign.in.css'
]},
{'www/css/cssui-dashboard.min.css': [
'node_modules/css-ui-dashboard/css/style.dashboard.css',
'node_modules/css-ui-dashboard/css/style.scrollbar.css'
]}
]
}
},
copy: {
main: {
files: [
{expand: true, cwd: 'node_modules/font-awesome/fonts/', src: ['**'], dest: 'www/fonts/'},
{expand: true, cwd: 'node_modules/open-sans-fontface/fonts/', src: ['**'], dest: 'www/css/fonts/'},
{expand: true, cwd: 'node_modules/css-ui-sign-in/img/', src: ['**'], dest: 'www/img/'},
{expand: true, cwd: 'node_modules/css-ui-dashboard/img/', src: ['**'], dest: 'www/img/'},
{expand: true, flatten: true, src: ['node_modules/css-ui-dashboard/css/style.css'], dest: 'www/css', filter: 'isFile'}
]
}
},
uglify: {
options: {
reserved: ['jQuery'],
sourceMap: true,
sourceMapName: 'www/js/main.map'
},
my_target: {
files: {
'www/js/main.min.js': [
'node_modules/jquery/dist/jquery.js',
'node_modules/perfect-scrollbar/dist/perfect-scrollbar.js',
'node_modules/nanobar/nanobar.js',
'node_modules/css-ui-responsive-menu/js/responsive.menu.js',
'node_modules/css-ui-dropdown-menu/js/dropdown.menu.js',
'node_modules/floatthead/src/jquery.floatThead.js'
]
}
}
}
});
grunt.loadNpmTasks('grunt-contrib-cssmin');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-copy');
grunt.registerTask('minify-all', ['cssmin', 'uglify', 'copy']);
};