-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathGruntfile.js
78 lines (71 loc) · 1.7 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
module.exports = function (grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
meta: {
banner: '/*! MultiSet - v<%= pkg.version %> - <%= grunt.template.today("yyyy-mm-dd") %>\n' +
' * Author: Alberto La Rocca <[email protected]> (https://github.com/71104)\n' +
' * Released under the MIT license\n' +
' * Copyright (c) <%= grunt.template.today("yyyy") %> Canvace Srl */\n'
},
jshint: {
options: {
camelcase: true,
curly: true,
forin: true,
immed: true,
indent: 4,
latedef: true,
newcap: true,
noarg: true,
quotmark: 'single',
undef: true,
unused: true,
strict: true,
trailing: true,
boss: true,
expr: true,
loopfunc: true,
smarttabs: true,
supernew: true,
exported: ['MultiSet']
},
dist: ['src/MultiSet.js']
},
clean: {
dist: ['bin', 'doc']
},
uglify: {
options: {
banner: '<%= meta.banner %>',
report: 'min'
},
dist: {
files: {
'bin/MultiSet-<%= pkg.version %>.js': ['src/MultiSet.js'],
'bin/node-multiset.js': [
'src/MultiSet.js',
'src/Module.js'
]
}
}
},
yuidoc: {
compile: {
name: 'MultiSet',
description: 'An utility class that implements a multiset, a set with possibly repeated elements.',
version: '<%= pkg.version %>',
url: '<%= pkg.homepage %>',
options: {
paths: 'src/',
outdir: 'doc/',
linkNatives: 'true'
}
}
}
});
grunt.loadNpmTasks('grunt-contrib-clean');
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-yuidoc');
grunt.registerTask('default', ['jshint', 'uglify', 'yuidoc']);
};