Skip to content
This repository has been archived by the owner on Dec 20, 2023. It is now read-only.

Node 5 updates #74

Merged
merged 2 commits into from
Jan 5, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions .gitmodules

This file was deleted.

24 changes: 12 additions & 12 deletions .jshintrc
Original file line number Diff line number Diff line change
@@ -1,22 +1,24 @@
{
"predef": [
"console",
"require"
"setImmediate"
],

"globals": {
"Promise": true,
"setImmediate": false
},
"node": true,
"browser": true,
"browser": false,
"devel": true,
"jquery": true,

"jquery": false,
"bitwise": false,
"camelcase": true,
"curly": true,
"eqeqeq": true,
"forin": false,
"immed": true,
"indent": 4,
"latedef": true,
"latedef": "nofunc",
"newcap": true,
"noarg": true,
"noempty": true,
Expand All @@ -26,15 +28,13 @@
"regexp": false,
"undef": true,
"unused": false,
"strict": false,
"strict": true,
"trailing": true,
"white": false,

"asi": false,
"boss": true,
"boss": false,
"debug": false,
"eqnull": true,
"es5": true,
"esnext": true,
"evil": false,
"expr": true,
Expand All @@ -53,6 +53,6 @@
"smarttabs": false,
"shadow": false,
"sub": true,
"supernew": false,
"supernew": true,
"validthis": false
}
}
12 changes: 11 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
before_script:
- npm install -g grunt-cli

sudo: false

after_script:
- grunt coveralls

language: node_js
node_js:
- "0.10"
- "4"
- "5"
- "stable"
120 changes: 120 additions & 0 deletions Gruntfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
"use strict";
/*global module:false*/
module.exports = function (grunt) {

// Automatic module definition loading. Significantly speeds up build cycles
require('jit-grunt')(grunt);

// Time how long tasks take. Can help when optimizing build times
require('time-grunt')(grunt);

// Project configuration.
var DEFAULT_COVERAGE_ARGS = ["cover", "-x", "Gruntfile.js", "--report", "none", "--print", "none", "--include-pid", "grunt", "--", "it"],
path = require("path");

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

comb: {
paths: {
root: './',
lib: './lib',
test: './test'
}
},

jshint: {
src: [
"./index.js",
"<%= comb.paths.lib %>/**/*.js",
"<%= comb.paths.test %>/**/*.js",
"Gruntfile.js"
],
options: {
jshintrc: '.jshintrc'
}
},

exec: {
sendToCoveralls: "cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js",
removeCoverage: "rm -rf ./coverage",
removeDocs: "rm -rf docs/*",
createDocs: 'coddoc -f multi-html -d ./lib --dir ./docs'
},

it: {
all: {
src: 'test/**/*.test.js',
options: {
timeout: 3000, // not fully supported yet
reporter: 'tap'
}
}
}
});

grunt.registerTask("benchmarks", "runs benchmarks", function () {
var done = this.async();
require("./benchmark/benchmark")()
.then(function () {
done(true);
})
.catch(function (err) {
console.log(err.stack || err);
done(false);

});
});

grunt.registerTask("spawn-test-coverage", "spawn tests with coverage", function () {
var done = this.async();
var env = process.env;
grunt.util.spawn({
cmd: "./node_modules/istanbul/lib/cli.js",
args: DEFAULT_COVERAGE_ARGS,
opts: {stdio: 'inherit', env: env}
}, function (err) {
if (err) {
console.log(err);
done(false);
} else {
done();
}
});
});


grunt.registerTask("process-coverage", "process coverage obects", function () {
var files = grunt.file.expand("./coverage/coverage*.json"),
istanbul = require('istanbul'),
collector = new istanbul.Collector(),
reporter = new istanbul.Reporter(),
sync = false,
done = this.async();

files.forEach(function (file) {
collector.add(grunt.file.readJSON(file));
});

reporter.add('text');
reporter.addAll(['lcovonly']);
reporter.write(collector, sync, function (err) {
if (err) {
console.error(err.stack);
return done(false);
}
console.log('All reports generated');
done();
});
});

grunt.registerTask('default', ['jshint', "test", "test-coverage", "docs"]);

grunt.registerTask('test', ['it']);

grunt.registerTask('coveralls', ['exec:removeCoverage', 'spawn-test-coverage', 'process-coverage', 'exec:sendToCoveralls', 'exec:removeCoverage']);
grunt.registerTask('test-coverage', ['exec:removeCoverage', 'spawn-test-coverage', 'process-coverage', 'exec:removeCoverage']);


grunt.registerTask("docs", ["exec:removeDocs", "exec:createDocs"]);
};
8 changes: 7 additions & 1 deletion History.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# 1.0.0

* Node 5 support
* Updated to use jshint
* Added grunt

# 0.4.1

* Adding `wrapStyle` option to `ConsoleAppender` to allow stripping of styling. Defaults to true.
Expand Down Expand Up @@ -297,4 +303,4 @@
#0.0.1 / 2011-05-19


* Initial release
* Initial release
41 changes: 0 additions & 41 deletions Makefile

This file was deleted.

23 changes: 12 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,27 +1,28 @@
[![build status](https://secure.travis-ci.org/C2FO/comb.png)](http://travis-ci.org/C2FO/comb)
[![build status](https://travis-ci.org/C2FO/comb.svg?branch=master)](http://travis-ci.org/C2FO/comb)
[![Coverage Status](https://coveralls.io/repos/C2FO/comb/badge.svg?branch=master&service=github)](https://coveralls.io/github/C2FO/comb?branch=master)

#Comb


##Overview

Framework for node that provides a one stop shop for frequently needed utilities, including:

* [OO utilties](http://c2fo.github.com/comb/define.html)
* Collections
* [Logging](http://c2fo.github.com/comb/logging.html)
* [String &amp; date formatting](http://c2fo.github.com/comb/utilities)
* [Flow control](http://c2fo.github.com/comb/promise.html)


##Installation

`npm install comb`

###[Getting Started](http://c2fo.github.com/comb/introduction.html)

##Highlights

* 100% test coverage!
* comb([define](http://c2fo.github.com/comb/comb.html#.define)|[singleton](http://c2fo.github.com/comb/comb.html#.singleton))
* The backbone of comb.
Expand Down Expand Up @@ -49,13 +50,13 @@ Framework for node that provides a one stop shop for frequently needed utilities
* [PriorityQueue](http://c2fo.github.com/comb/comb_collections_PriorityQueue.html)
* [Queue](http://c2fo.github.com/comb/comb_collections_Queue.html)
* [Stack](http://c2fo.github.com/comb/comb_collections_Stack.html)

* [Flow control](http://c2fo.github.com/comb/promise.html)
* [Promises](http://c2fo.github.com/comb/comb_Promise.html)
* [PromiseList](http://c2fo.github.com/comb/comb_PromiseList.html)
* [comb.when](http://c2fo.github.com/comb/comb.html#.when)
* [comb.serial](http://c2fo.github.com/comb/comb.html#.serial)

##License


Expand Down
Loading