Permalink
Browse files

introduced grunt fixing #56 from forked repo (the main one). Running …

…tests, sometimes I receive 5 or 6 fails (Dunno why this unregularity) but anyway this behaviour occured also before this commit...
  • Loading branch information...
wouldgo committed Feb 9, 2014
1 parent 6498328 commit e5f54140e98364a5cd355971793c927ee6316a6c
Showing with 844 additions and 642 deletions.
  1. +25 −0 .jshintrc
  2. +68 −0 Gruntfile.js
  3. +206 −201 bin/build.js
  4. +96 −115 bin/clean.js
  5. +1 −1 lib/browser.js
  6. +29 −9 lib/datachannel.js
  7. +13 −12 lib/error.js
  8. +2 −1 lib/icecandidate.js
  9. +2 −1 lib/icecandidateevent.js
  10. +31 −11 lib/mediastream.js
  11. +34 −12 lib/mediastreamtrack.js
  12. +59 −22 lib/peerconnection.js
  13. +3 −2 lib/sessiondescription.js
  14. +10 −2 package.json
  15. +150 −146 test/connect.js
  16. +60 −56 test/create-offer.js
  17. +55 −51 test/sessiondesc.js
View
@@ -0,0 +1,25 @@
+//http://www.jshint.com/docs/options/
+{
+ "bitwise": false,
+ "laxcomma": true,
+ "camelcase": true,
+ "curly": true,
+ "eqeqeq": true,
+ "immed": true,
+ "indent": 2,
+ "latedef": true,
+ "newcap": true,
+ "noarg": true,
+ "noempty": true,
+ "nonew": true,
+ "plusplus": true,
+ "quotmark": "single",
+ "undef": true,
+ "unused": true,
+ "strict": true,
+ "trailing" :true,
+ "node": true,
+ "browser": true,
+ "globals": {
+ }
+}
View
@@ -0,0 +1,68 @@
+'use strict';
+
+module.exports = function(grunt) {
+
+ var banner = ['/*!',
+ ' * node-webrtc v<%= pkg.version %>',
+ ' *',
+ ' * Released under the BSD license',
+ ' *',
+ ' * <%= grunt.template.today("yyyy-mm-dd") %>',
+ ' */\n\n'
+ ].join('\n');
+
+ grunt.initConfig({
+ pkg: grunt.file.readJSON('package.json'),
+ jshint: {
+ options: {
+ jshintrc: '.jshintrc'
+ },
+ gruntfile: {
+ src: 'Gruntfile.js'
+ },
+ lib: {
+ src: [
+ 'lib/**.js',
+ 'bin/**.js'
+ ]
+ },
+ test: {
+ src: [
+ 'test/**.js'
+ ]
+ }
+ },
+ tape: {
+ options: {
+ pretty: true,
+ output: 'console'
+ },
+ files: ['test/all.js']
+ },
+ uglify: {
+ options: {
+ report: 'gzip',
+ banner: banner
+ },
+ minifyTarget: {
+ files: {
+ 'dist/node-webrtc.min.js': [
+ 'first.js',
+ 'second.js',
+ '....'
+ ]
+ }
+ }
+ }
+ });
+
+ grunt.loadNpmTasks('grunt-contrib-jshint');
+ grunt.loadNpmTasks('grunt-tape');
+ grunt.loadNpmTasks('grunt-contrib-uglify');
+
+ // Default tasks (when type grunt on terminal).
+ grunt.registerTask('default', [
+ 'jshint',
+ 'tape'
+ ]);
+};
Oops, something went wrong.

0 comments on commit e5f5414

Please sign in to comment.