Skip to content

Commit

Permalink
Merge branch 'peers-master'
Browse files Browse the repository at this point in the history
  • Loading branch information
ericz committed Sep 28, 2014
2 parents 7307baa + 78e5ab2 commit f6230cb
Show file tree
Hide file tree
Showing 11 changed files with 81 additions and 820 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
dist/
node_modules/
Empty file added .npmignore
Empty file.
51 changes: 51 additions & 0 deletions Gruntfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
module.exports = function(grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),

browserify: {
dev: {
options: {
prepend: ['/*! binarypack.js build:<%= pkg.version %>, development. '+
'Copyright(c) 2012 Eric Zhang <eric@ericzhang.com> MIT Licensed */']
},
src: ['lib/exports.js'],
dest: 'dist/binarypack.js'
}
},

uglify: {
prod: {
options: {
mangle: true, compress: true,
},
src: 'dist/binarypack.js',
dest: 'dist/binarypack.min.js'
}
},

concat: {
dev: {
options: {
banner: '/*! binarypack.js build:<%= pkg.version %>, production. '+
'Copyright(c) 2012 Eric Zhang <eric@ericzhang.com> MIT Licensed */'
},
src: 'dist/binarypack.js',
dest: 'dist/binarypack.js',
},
prod: {
options: {
banner: '/*! binarypack.js build:<%= pkg.version %>, production. '+
'Copyright(c) 2012 Eric Zhang <eric@ericzhang.com> MIT Licensed */'
},
src: 'dist/binarypack.min.js',
dest: 'dist/binarypack.min.js',
}
}
});

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

grunt.registerTask('default', ['browserify', 'uglify', 'concat']);
}
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
default: compress

compress:
@node bin/build.js;
@./node_modules/.bin/grunt
211 changes: 0 additions & 211 deletions bin/build.js

This file was deleted.

Loading

0 comments on commit f6230cb

Please sign in to comment.