Skip to content

Commit

Permalink
add grunt for building
Browse files Browse the repository at this point in the history
  • Loading branch information
bkw committed Aug 7, 2013
1 parent 1832c02 commit 6625c22
Show file tree
Hide file tree
Showing 4 changed files with 61 additions and 1,204 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
node_modules
dist/broadway.js
.*.swp
.DS_Store
49 changes: 49 additions & 0 deletions Gruntfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
module.exports = function (grunt) {
'use strict';
// load all grunt tasks
require('matchdep').filterDev('grunt-*').forEach(grunt.loadNpmTasks);

grunt.initConfig({

pkg: grunt.file.readJSON('package.json'),

jshint: {
options: {
jshintrc: '.jshintrc'
},
all: [
'Gruntfile.js',
'lib/{,*/}*.js',
'dist/nodecopter-stream.js'
]
},

uglify: {
dist: {
files: {
'dist/broadway.js' : [
'dist/vendor/broadway/glUtils.js',
'dist/vendor/broadway/util.js',
'dist/vendor/broadway/avc.js',
'dist/vendor/broadway/canvas.js',
'dist/nodecopter-stream.js'
]
}
}
},
concat: {
options: {
banner: '/*! <%= pkg.name %> <%= grunt.template.today("dd-mm-yyyy") %> */\n'
},
dist: {
src: [
'dist/vendor/broadway/sylvester.js',
'dist/vendor/broadway/avc-codec.js',
'dist/broadway.js'
],
dest: 'dist/nodecopter-client.js'
}
}
});
grunt.registerTask('default', ['jshint', 'uglify', 'concat']);
};
Loading

0 comments on commit 6625c22

Please sign in to comment.