Skip to content

Commit a2add6a

Browse files
committed
Update gruntfile to v0.4
1 parent 079d548 commit a2add6a

File tree

4 files changed

+57
-43
lines changed

4 files changed

+57
-43
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/node_modules/

Gruntfile.js

+41
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
/*
2+
Build environment
3+
----------------------------------------
4+
1) Install NodeJS:
5+
http://nodejs.org/
6+
2) Install dev dependencies
7+
npm install
8+
3) Install Grunt CLI globally
9+
npm install grunt-cli -g
10+
*/
11+
12+
module.exports = function (grunt) {
13+
grunt.initConfig({
14+
concat: {
15+
'build/MIDI.js': [
16+
'js/MIDI/AudioDetect.js',
17+
'js/MIDI/LoadPlugin.js',
18+
'js/MIDI/Plugin.js',
19+
'js/MIDI/Player.js',
20+
'js/Window/DOMLoader.XMLHttp.js', // req when using XHR
21+
'js/Window/DOMLoader.script.js', // req otherwise
22+
// 'js/Color/SpaceW3.js', // optional
23+
// 'js/MusicTheory/Synesthesia.js', // optional
24+
// 'js/Widgets/Loader.js', // optional
25+
// 'js/Window/Event.js' // optional
26+
]
27+
},
28+
uglify: {
29+
'build/MIDI.min.js': [
30+
'build/MIDI.js'
31+
]
32+
}
33+
});
34+
35+
grunt.loadNpmTasks('grunt-contrib-concat');
36+
grunt.loadNpmTasks('grunt-contrib-uglify');
37+
38+
///
39+
grunt.registerTask('default', ['concat', 'uglify']);
40+
///
41+
};

grunt.js

-35
This file was deleted.

package.json

+15-8
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,21 @@
33
"version": "0.3.0",
44
"description": "Library to assist in creating HTML5 MIDI apps.",
55
"author": "Michael Deal",
6-
"contributors" : [ "Sergi Mansilla", "Daniel van der Meer", "Mohit Muthanna", "Pete Otaqui" ],
7-
"scripts": {
8-
"preinstall": "grunt"
9-
},
6+
"contributors": [
7+
"Sergi Mansilla",
8+
"Daniel van der Meer",
9+
"Mohit Muthanna",
10+
"Pete Otaqui"
11+
],
1012
"repository": {
11-
"type": "git",
12-
"url": "git://github.com/mudcube/MIDI.js.git"
13+
"type": "git",
14+
"url": "git://github.com/mudcube/MIDI.js.git"
1315
},
1416
"main": "./build/MIDI.min.js",
15-
"license": "MIT"
16-
}
17+
"license": "MIT",
18+
"devDependencies": {
19+
"grunt": "~0.4.0",
20+
"grunt-contrib-concat": "~0.1.3",
21+
"grunt-contrib-uglify": "~0.1.2"
22+
}
23+
}

0 commit comments

Comments
 (0)