Skip to content

Commit

Permalink
Enable Layout/EmptyLinesAroundAccessModifier cop
Browse files Browse the repository at this point in the history
### Summary

Follow up rails/rails#36472.

This PR enables `Layout/EmptyLinesAroundAccessModifier` cop with
`EnforcedStyle: only_before`.

### Other Information

This enforced style was introduced with RuboCop 0.70.
https://github.com/rubocop-hq/rubocop/blob/master/CHANGELOG.md#0700-2019-05-21
  • Loading branch information
koic committed Jun 16, 2019
1 parent eca418e commit 2c854db
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
4 changes: 4 additions & 0 deletions config/rails.yml
Expand Up @@ -61,6 +61,10 @@ Layout/EndAlignment:
Layout/EmptyLineAfterMagicComment:
Enabled: true

Layout/EmptyLinesAroundAccessModifier:
Enabled: true
EnforcedStyle: only_before

Layout/EmptyLinesAroundBlockBody:
Enabled: true

Expand Down
1 change: 0 additions & 1 deletion lib/generators/rubocop_rails_config/install_generator.rb
Expand Up @@ -14,7 +14,6 @@ def create_config_file
end

private

def config_file_exists?
File.exist?(config_file_path)
end
Expand Down
1 change: 0 additions & 1 deletion lib/generators/rubocop_rails_config/update_generator.rb
Expand Up @@ -17,7 +17,6 @@ def update_config_file
end

private

# rubocop-rails is renamed to rubocop-rails_config
def old_gem_name_used?
File.foreach(config_file_path).grep(/\s+rubocop-rails:/).any?
Expand Down

0 comments on commit 2c854db

Please sign in to comment.