-
Notifications
You must be signed in to change notification settings - Fork 106
/
Gruntfile.js
72 lines (65 loc) · 1.99 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
module.exports = function (grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
concat: {
options: {
separator: '\r\n\r\n'
},
dist: {
src: [
'src/modules/soundmanager2.js',
'src/01-app.js',
'src/02-filter-humanTime.js',
'src/03-factory-angularPlayer.js',
'src/04-directive-soundManager.js',
'src/05-directive-musicPlayer.js',
'src/06-directive-playFromPlaylist.js',
'src/07-directive-removeFromPlaylist.js',
'src/08-directive-seekTrack.js',
'src/09-directive-playMusic.js',
'src/10-directive-pauseMusic.js',
'src/11-directive-stopMusic.js',
'src/12-directive-nextTrack.js',
'src/13-directive-prevTrack.js',
'src/14-directive-muteMusic.js',
'src/15-directive-repeatMusic.js',
'src/16-directive-musicVolume.js',
'src/17-directive-clearPlaylist.js',
'src/18-directive-playAll.js',
'src/19-directive-volumeBar.js',
'src/20-directive-playPauseToggle.js',
],
dest: 'dist/angular-soundmanager2.js'
}
},
uglify: {
options: {
banner: '/*! <%= pkg.name %> <%= grunt.template.today("dd-mm-yyyy") %> */\n'
},
dist: {
files: {
'dist/angular-soundmanager2.min.js': ['dist/angular-soundmanager2.js']
}
}
},
jshint: {
files: ['gruntfile.js', 'src/*.js', 'src/modules/*.js'],
options: {
globals: {
jQuery: true,
console: true,
module: true
}
}
},
watch: {
files: ['<%= jshint.files %>'],
tasks: ['concat', 'uglify', 'jshint']
}
});
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.registerTask('default', ['concat', 'uglify', 'jshint', 'watch']);
};