Grunt task for validating Ruby code.
You need to have the ruby-lint
command available on your system.
gem install ruby-lint
This plugin requires Grunt ~0.4.0
npm install grunt-contrib-rubylint --save-dev
grunt.loadNpmTasks('grunt-contrib-rubylint');
grunt.initConfig({
rubylint: {
options: {
levels: 'error'
},
src: ['**/*.{rb,ru}']
}
});
grunt.loadNpmTasks('grunt-contrib-rubylint');
Type: Boolean
Default value: false
Set force
to true to report errors but not fail the task.
Type: String
Default value: error
Set levels
to one of the following:
- error
- info
- warning
Type: Object
Default value: []
Set analysis
to true to report errors but not fail the task.
If no value is set, all classes are used.
Else, pick the classes you want to use in the following list:
- argument_amount
- pedantics
- shadowing_variables
- undefined_methods
- undefined_variables
- unused_variables
- useless_equality_checks
This package is published under the MIT license.