Skip to content

Commit

Permalink
add grunt to project
Browse files Browse the repository at this point in the history
  • Loading branch information
naomiaro committed Apr 22, 2015
1 parent 118c82b commit 2e00c42
Show file tree
Hide file tree
Showing 2 changed files with 63 additions and 0 deletions.
48 changes: 48 additions & 0 deletions Gruntfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
module.exports = function(grunt) {

// Project configuration.
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
concat: {
options: {
stripBanners: true,
banner: '/*! <%= pkg.name %> <%= pkg.version %>\n'
+ 'Written by: <%= pkg.author %>\n'
+ 'Website: <%= pkg.website %>\n'
+ 'License: <%= pkg.license %> */\n'
},
dist: {
src: [
'js/waveform/observer/observer.js',
'js/waveform/local_storage.js',
'js/waveform/config.js',
'js/waveform/curves.js',
'js/waveform/track_render.js',
'js/waveform/fades.js',
'js/waveform/playout.js',
'js/waveform/track.js',
'js/waveform/time_scale.js',
'js/waveform/controls.js',
'js/waveform/playlist.js'
],
dest: 'dist/<%= pkg.name %>.js'
}
},
uglify: {
options: {
banner: '<%= concat.options.banner %>'
},
build: {
src: '<%= concat.dist.dest %>',
dest: 'dist/<%= pkg.name %>.min.js'
}
}
});

grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-uglify');

// Default task(s).
grunt.registerTask('default', ['concat', 'uglify']);

};
15 changes: 15 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"name": "waveform-playlist",
"description": "Multiple track web audio editor and player with waveform preview",
"version": "0.1.0",
"author": "Naomi Aro",
"license": "MIT",
"website": "http://naomiaro.github.io/waveform-playlist",
"devDependencies": {
"grunt": "~0.4.5",
"grunt-contrib-concat": "^0.5.1",
"grunt-contrib-jshint": "~0.10.0",
"grunt-contrib-nodeunit": "~0.4.1",
"grunt-contrib-uglify": "~0.5.0"
}
}

0 comments on commit 2e00c42

Please sign in to comment.