Last Updated: February 25, 2016
·
1.293K
· mrclmrvn

add rubocop in rake

Install rubocop

desc 'run rubocop'
task(:rubocop) do
  require 'rubocop'
  cli = RuboCop::CLI.new
  cli.run
end

task default: [:rubocop, :test]

require File.expand_path('../config/application', __FILE__)

MyApp::Application.load_tasks

Then, just configure .rubocop.yml to your needs here