-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathgruntfile.js
More file actions
54 lines (48 loc) · 1.42 KB
/
gruntfile.js
File metadata and controls
54 lines (48 loc) · 1.42 KB
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
module.exports = function(grunt) {
"use strict";
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
jshint: {
options: {
jshintrc: '.jshintrc'
},
all: ["source/jquery.getscripts.js"]
},
qunit: {
options: {
timeout: 10000
},
all: ['tests/*.html']
},
uglify: {
options: {
compress: true,
mangle: true,
banner: '/**\n' +
'* <%= pkg.title %> v<%= pkg.version %>\n' +
'* <%= pkg.homepage %>\n' +
'*\n' +
'* <%= pkg.description %>\n' +
'*\n' +
'* Copyright <%= grunt.template.today("yyyy") %> <%= pkg.author.name %>\n' +
'*\n' +
'* Released Under the Following Licenses\n' +
'* <%= _.pluck(pkg.licenses, "url").join(", ") %>\n' +
'*\n' +
'* Date: <%= grunt.template.date(Date.now(), "isoDateTime") %>\n' +
'*/\n'
},
all: {
files: {
'dist/jquery.getscripts.min.js': ['source/jquery.getscripts.js'],
}
}
}
});
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-qunit');
grunt.registerTask('test', ['jshint', 'qunit']);
grunt.registerTask('dist', ['test', 'uglify']);
grunt.registerTask('default', ['dist']);
};