-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathGruntfile.js
executable file
·63 lines (57 loc) · 2.4 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
'use strict';
module.exports = function (grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
uglify: {
development: {
forceOverwrite: true,
files: [{
expand: true,
cwd: 'js/',
src: ['pages/account.js','pages/calendar.js','pages/category.js','pages/dashboard.js',
'pages/insights.js','pages/reconciliation.js','pages/search.js','pages/settings.js',
'pages/transactions','accounts_selector.js','app.js','charts.js','create_transaction.js',
'custom-datepicker.js','pages/users.js','pages/updates.js','pages/repeat_transactions.js'],
dest: 'public/assets/js/'
}]
},
options: {
mangle: false,
compress: {
drop_console: true
},
},
},
concat: {
options: {
separator: ';',
},
dist: {
src: ['js/jquery.js','js/bootstrap.bundle.js',
'js/Chart.js','js/jquery.validate.min.js','js/jquery.easing.min.js',
'js/bootstrap-datepicker.min.js','js/moment.min.js','js/fullcalendar.bundle.js',
'js/jquery.dataTables.min.js','js/dataTables.bootstrap4.min.js','js/notify.min.js',
'js/jquery-confirm.min.js','js/select2.min.js'],
dest: 'public/assets/js/built.js',
},
},
concat_css: {
options: {
// Task-specific options go here.
},
all: {
src: ['css/all.min.css','css/sb-admin-2.css','css/primary.css','css/main.css',
'css/fullcalendar.bundle.css','css/three-dots.min.css','css/dataTables.bootstrap4.min.css',
'css/bootstrap-datepicker.min.css','css/jquery-confirm.min.css','css/select2.min.css'],
dest: "public/assets/css/styles.css"
},
},
});
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-concat-css');
grunt.registerTask('css', ['concat_css']);
grunt.registerTask('js', ['concat','uglify']);
grunt.registerTask('ugly',['uglify']);
grunt.registerTask('default', ['concat','uglify','concat_css']);
}