Skip to content

Commit

Permalink
chore: Resolve or ignore Metrics/BlockLength
Browse files Browse the repository at this point in the history
  • Loading branch information
turboladen committed Jan 19, 2023
1 parent 7a9d635 commit 19798bb
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 11 deletions.
1 change: 1 addition & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Layout/ParameterAlignment:

Metrics/BlockLength:
Exclude:
- ffi-gdal.gemspec
- spec/**/*_spec.rb
- spec/support/shared_examples/**/*.rb

Expand Down
14 changes: 4 additions & 10 deletions .rubocop_todo.yml
Original file line number Diff line number Diff line change
@@ -1,22 +1,16 @@
# This configuration was generated by
# `rubocop --auto-gen-config`
# on 2022-12-29 19:47:47 UTC using RuboCop version 1.41.1.
# on 2023-01-18 23:16:34 UTC using RuboCop version 1.43.0.
# The point is for the user to remove these configuration records
# one by one as the offenses are removed from the code base.
# Note that changes in the inspected code, or installation of new
# versions of RuboCop, may require this file to be generated again.

# Offense count: 46
# Offense count: 42
# Configuration parameters: AllowedMethods, AllowedPatterns, IgnoredMethods, CountRepeatedAttributes.
Metrics/AbcSize:
Max: 86

# Offense count: 3
# Configuration parameters: CountComments, CountAsOne, ExcludedMethods, AllowedMethods, AllowedPatterns, IgnoredMethods.
# AllowedMethods: refine
Metrics/BlockLength:
Max: 54

# Offense count: 9
# Configuration parameters: CountComments, CountAsOne.
Metrics/ClassLength:
Expand All @@ -27,7 +21,7 @@ Metrics/ClassLength:
Metrics/CyclomaticComplexity:
Max: 21

# Offense count: 93
# Offense count: 88
# Configuration parameters: CountComments, CountAsOne, ExcludedMethods, AllowedMethods, AllowedPatterns, IgnoredMethods.
Metrics/MethodLength:
Max: 78
Expand All @@ -37,7 +31,7 @@ Metrics/MethodLength:
Metrics/ModuleLength:
Max: 533

# Offense count: 22
# Offense count: 20
# Configuration parameters: CountKeywordArgs, MaxOptionalParameters.
Metrics/ParameterLists:
Max: 9
Expand Down
13 changes: 13 additions & 0 deletions .solargraph.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
include:
- "**/*.rb"
exclude:
- spec/**/*
- test/**/*
- vendor/**/*
- ".bundle/**/*"
require: []
domains: []
reporters:
- all!
max_files: 5000
2 changes: 1 addition & 1 deletion lib/ffi/ogr/srs_api.rb
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ module SRSAPI
# -----------------------------------------------------------------------
# Constants
# -----------------------------------------------------------------------
SRS_UL = FFI::ConstGenerator.new("SRS_UL") do |gen|
SRS_UL = FFI::ConstGenerator.new("SRS_UL") do |gen| # rubocop:disable Metrics/BlockLength
gen.include FFI::GDAL._file_with_constants("ogr_srs_api.h")
gen.const :SRS_UL_METER, "%s", nil, :METER_LABEL, &:inspect
gen.const :SRS_UL_FOOT, "%s", nil, :FOOT_LABEL, &:inspect
Expand Down

0 comments on commit 19798bb

Please sign in to comment.