Skip to content

Commit

Permalink
Switch to Grunt for builds
Browse files Browse the repository at this point in the history
  • Loading branch information
notheotherben committed May 18, 2015
1 parent 32b84b2 commit 163e1bf
Show file tree
Hide file tree
Showing 38 changed files with 240 additions and 413 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,5 @@ node_modules/
dist/
*.tmp
coverage/
*.d.ts
*.d.ts
.tscache
87 changes: 87 additions & 0 deletions Gruntfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
var tsconfig = require('./tsconfig.json');

module.exports = function (grunt) {
"use strict";

grunt.initConfig({
ts: {
options: tsconfig.compilerOptions,

dev: {
src: tsconfig.files,
reference: 'iridium.d.ts',
watch: 'lib'
},
test: {
src: tsconfig.files,
reference: 'iridium.d.ts',
options: {
sourceMap: true
}
},
release: {
src: tsconfig.files,
reference: 'iridium.d.ts',
options: {
sourceMap: false
}
}
},
mochacli: {
options: {
require: ["test/support/chai", "test/support/config"],
files: "test/*.js",
timeout: '10s'
},

default: {

}
},
mocha_istanbul: {
coverage: {
src: 'test',
root: 'lib',
options: {
mask: '*.js',
reportFormats: ['lcovonly'],
timeout: '10s',
require: ["test/support/chai", "test/support/config"],
check: {
lines: 75,
statements: 75
}
}
},

coveralls: {
src: 'test',
root: 'lib',
options: {
mask: '*.js',
coverage: true,
reportFormats: ['lcovonly'],
timeout: '10s',
require: ["test/support/chai", "test/support/config"]
}
}
}
});

grunt.event.on('coverage', function (lcovcontent, done) {
require('coveralls').handleInput(lcovcontent, function (err) {
if (err) return done(err);
done();
});
});

grunt.loadNpmTasks("grunt-ts");
grunt.loadNpmTasks("grunt-mocha-cli");
grunt.loadNpmTasks("grunt-mocha-istanbul");

grunt.registerTask("default", ["ts:dev"]);
grunt.registerTask("test", ["ts:test", "mochacli"]);
grunt.registerTask("coverage", ["ts:test", "mocha_istanbul:coverage"]);
grunt.registerTask("coveralls", ["ts:test", "mocha_istanbul:coveralls"]);
grunt.registerTask("release", ["ts:release"]);
};
2 changes: 1 addition & 1 deletion index.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

41 changes: 0 additions & 41 deletions lib/Core.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/Core.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 163e1bf

Please sign in to comment.