diff --git a/.rubocop.yml b/.rubocop.yml index 7354247c..8c3e71ab 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -1,3 +1,6 @@ +require: + - rubocop-rake + inherit_from: .rubocop_todo.yml inherit_mode: diff --git a/Rakefile b/Rakefile index 91b9e051..d36e1221 100644 --- a/Rakefile +++ b/Rakefile @@ -82,6 +82,7 @@ namespace 'test' do # rubocop:disable Metrics/BlockLength end end +desc 'Run linters' task 'lint' do if defined?(RuboCop::RakeTask) RuboCop::RakeTask.new @@ -132,10 +133,12 @@ if ENV['MOCHA_GENERATE_DOCS'] task.options = ['--title', "Mocha #{Mocha::VERSION}", '--fail-on-warning'] end + desc 'Ensure custom domain remains in place for docs on GitHub Pages' task 'checkout_docs_cname' do `git checkout docs/CNAME` end + desc 'Ensure custom JavaScript files remain in place for docs on GitHub Pages' task 'checkout_docs_js' do `git checkout docs/js/app.js` `git checkout docs/js/jquery.js` diff --git a/gemfiles/Gemfile.rubocop b/gemfiles/Gemfile.rubocop index 61f5d370..ac47c262 100644 --- a/gemfiles/Gemfile.rubocop +++ b/gemfiles/Gemfile.rubocop @@ -4,3 +4,4 @@ gemspec path: '../' gem 'rake' gem 'rubocop' +gem 'rubocop-rake'