j5-rc-receiver
Version:
Nintendo RC Receiver component class plugin for Johnny-Five
74 lines (67 loc) • 1.58 kB
JavaScript
module.exports = function(grunt) {
// Project configuration.
grunt.initConfig({
nodeunit: {
tests: [
"test/**/*.js"
]
},
jshint: {
options: {
jshintrc: ".jshintrc"
},
all: [
"index.js",
"test/**/*.js",
"Gruntfile.js",
]
},
jscs: {
all: [
"index.js",
"test/**/*.js",
"Gruntfile.js",
],
options: {
config: ".jscsrc"
}
},
jsbeautifier: {
all: [
"index.js",
"test/**/*.js",
"Gruntfile.js",
],
options: {
js: {
braceStyle: "collapse",
breakChainedMethods: false,
e4x: false,
evalCode: false,
indentChar: " ",
indentLevel: 0,
indentSize: 2,
indentWithTabs: false,
jslintHappy: false,
keepArrayIndentation: false,
keepFunctionIndentation: false,
maxPreserveNewlines: 10,
preserveNewlines: true,
spaceBeforeConditional: true,
spaceInParen: false,
unescapeStrings: false,
wrapLineLength: 0
}
}
}
});
// These plugins provide necessary tasks.
grunt.loadNpmTasks("grunt-contrib-jshint");
grunt.loadNpmTasks("grunt-contrib-nodeunit");
grunt.loadNpmTasks("grunt-jscs");
grunt.loadNpmTasks("grunt-jsbeautifier");
// "npm test" runs these tasks
grunt.registerTask("test", ["jshint", "jscs", "nodeunit"]);
// Default task.
grunt.registerTask("default", ["test"]);
};