From 253026470884f90d1c70982a7e21b1bd76b0958d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Lecour?= Date: Thu, 14 Jun 2018 22:17:11 +0200 Subject: [PATCH] Improve rubocop (#28) Add good settings for Rubocop from DNSimple blog : https://blog.dnsimple.com/2018/06/quick-tips-for-practical-rubocop-workflow/ Add Rubocop command in INSTALL.md --- .rubocop.yml | 4 +++- INSTALL.md | 2 ++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.rubocop.yml b/.rubocop.yml index fe827c6..2ea75a0 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -1,4 +1,7 @@ AllCops: + DisplayCopNames: true + DisplayStyleGuide: true + ExtraDetails: false TargetRubyVersion: 2.5 Exclude: - 'node_modules/**/*' @@ -29,7 +32,6 @@ Metrics/BlockLength: Exclude: - lib/tasks/**/* - AsciiComments: Enabled: false diff --git a/INSTALL.md b/INSTALL.md index 669db72..414696a 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -72,6 +72,8 @@ This will also generate a code coverage report in `coverage/index.html`. With `# bundle exec guard` your test suite is run completely a first time, then once for each file you change and save. Take a look at https://guardgem.org for more information. +To execute Rubocop (the style-guide linter for Ruby), run `# bundle exec rubocop`. + ## Local execution If you want to start the Rails application manually, with a simple Puma configuration, you have to execute `# bundle exec rails server`. You will be able to open http://127.0.0.1:3000 in your browser and see Chexpire in action.