rubocop-cargosense 4.0.0 → 5.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: fdb8c9e0d9dc008c27ab21a7b3245d5b19fe86b2c70e93331f9e96e155119d16
4
- data.tar.gz: 76348e8ef6a212f5cae80ea60932e8feeb08368ee85bf9ad9bb6e0342cc6d6f6
3
+ metadata.gz: 3a2d54c2678ac20ccb034aadb177502419dd2713e1fb0b04ebe08c909b70756d
4
+ data.tar.gz: 864c7885e5456bfde5b4d67d12d9aee93aff61e5964fc07345275546502f3976
5
5
  SHA512:
6
- metadata.gz: a06c36046a17a7bd3885327da40befdeb43b50d81050a50f89cafbef3bd2630ff6b106f3c3ac45b3278684c5112805b4cc7cd57b08eb37e12dfba6064a782803
7
- data.tar.gz: 7780994fca4779b0991fea24e662ba82ff42bf07b579a45d0f85c8f91d399e6491a54761b20cedd0be969b5d69f0503755cf93f55b5c09ebd56594f8e40178b6
6
+ metadata.gz: dc7737213907109e1b2075df2a9bcba9a36fbadbbafd8339a66fad020ece4f632b848ae73f8b66349e5583529589b304fb490642a04bd142eb23c062c895893b
7
+ data.tar.gz: 752e90c4805452b230f5173b2235821743972db52fd267b959446e15dfb6a1143ef288143efd7521fbc10cd9d577067b0560aac8248e113786378d8a62cf2baa
@@ -5,7 +5,7 @@
5
5
  # @see https://docs.rubocop.org/rubocop-performance
6
6
  # @see https://github.com/rubocop/rubocop-performance
7
7
 
8
- require: rubocop-performance
8
+ plugins: rubocop-performance
9
9
 
10
10
  Performance/ChainArrayAllocation:
11
11
  Enabled: true
@@ -5,7 +5,7 @@
5
5
  # @see https://docs.rubocop.org/rubocop-rails
6
6
  # @see https://github.com/rubocop/rubocop-rails
7
7
 
8
- require: rubocop-rails
8
+ plugins: rubocop-rails
9
9
 
10
10
  Rails/DefaultScope:
11
11
  Enabled: true
@@ -3,4 +3,4 @@
3
3
  # @see https://rubygems.org/gems/rubocop-rake
4
4
  # @see https://github.com/rubocop/rubocop-rake
5
5
 
6
- require: rubocop-rake
6
+ plugins: rubocop-rake
@@ -5,7 +5,7 @@
5
5
  # @see https://docs.rubocop.org/rubocop-rspec
6
6
  # @see https://github.com/rubocop/rubocop-rspec
7
7
 
8
- require: rubocop-rspec
8
+ plugins: rubocop-rspec
9
9
 
10
10
  RSpec/DescribedClassModuleWrapping:
11
11
  Enabled: true
@@ -0,0 +1,30 @@
1
+ # frozen_string_literal: true
2
+
3
+ require "lint_roller"
4
+
5
+ module RuboCop
6
+ module CargoSense
7
+ class Plugin < LintRoller::Plugin
8
+ def about
9
+ LintRoller::About.new(
10
+ name: NAME,
11
+ version: VERSION,
12
+ homepage: HOMEPAGE,
13
+ description: DESCRIPTION
14
+ )
15
+ end
16
+
17
+ def rules(_context)
18
+ LintRoller::Rules.new(
19
+ type: :path,
20
+ config_format: :rubocop,
21
+ value: Pathname.new(__dir__).join("../../../config/default.yml")
22
+ )
23
+ end
24
+
25
+ def supported?(context)
26
+ context.engine == :rubocop
27
+ end
28
+ end
29
+ end
30
+ end
@@ -2,10 +2,9 @@
2
2
 
3
3
  module RuboCop
4
4
  module CargoSense
5
- PROJECT_ROOT = Pathname.new(__dir__).parent.parent.expand_path.freeze
6
- CONFIG_DEFAULT = PROJECT_ROOT.join("config", "default.yml").freeze
7
- CONFIG = YAML.safe_load(CONFIG_DEFAULT.read).freeze
8
-
9
- private_constant :CONFIG_DEFAULT, :PROJECT_ROOT
5
+ NAME = "rubocop-cargosense"
6
+ VERSION = "5.0.0"
7
+ HOMEPAGE = "https://github.com/CargoSense/rubocop-cargosense"
8
+ DESCRIPTION = "Reusable RuboCop configuration for CargoSense's Ruby projects."
10
9
  end
11
10
  end
@@ -1,10 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  require "rubocop"
4
- require "rubocop-performance"
5
- require "rubocop-rake"
6
4
 
7
5
  require_relative "rubocop/cargosense"
8
- require_relative "rubocop/cargosense/inject"
9
-
10
- RuboCop::CargoSense::Inject.defaults!
6
+ require_relative "rubocop/cargosense/plugin"
metadata CHANGED
@@ -1,29 +1,49 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rubocop-cargosense
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.0
4
+ version: 5.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - CargoSense
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-01-06 00:00:00.000000000 Z
11
+ date: 2025-02-24 00:00:00.000000000 Z
12
12
  dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: lint_roller
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
13
27
  - !ruby/object:Gem::Dependency
14
28
  name: rubocop
15
29
  requirement: !ruby/object:Gem::Requirement
16
30
  requirements:
17
31
  - - "~>"
18
32
  - !ruby/object:Gem::Version
19
- version: '1.64'
33
+ version: '1.72'
34
+ - - ">="
35
+ - !ruby/object:Gem::Version
36
+ version: 1.72.2
20
37
  type: :runtime
21
38
  prerelease: false
22
39
  version_requirements: !ruby/object:Gem::Requirement
23
40
  requirements:
24
41
  - - "~>"
25
42
  - !ruby/object:Gem::Version
26
- version: '1.64'
43
+ version: '1.72'
44
+ - - ">="
45
+ - !ruby/object:Gem::Version
46
+ version: 1.72.2
27
47
  - !ruby/object:Gem::Dependency
28
48
  name: rubocop-capybara
29
49
  requirement: !ruby/object:Gem::Requirement
@@ -64,62 +84,62 @@ dependencies:
64
84
  requirements:
65
85
  - - "~>"
66
86
  - !ruby/object:Gem::Version
67
- version: '1.20'
87
+ version: '1.24'
68
88
  type: :runtime
69
89
  prerelease: false
70
90
  version_requirements: !ruby/object:Gem::Requirement
71
91
  requirements:
72
92
  - - "~>"
73
93
  - !ruby/object:Gem::Version
74
- version: '1.20'
94
+ version: '1.24'
75
95
  - !ruby/object:Gem::Dependency
76
96
  name: rubocop-rails
77
97
  requirement: !ruby/object:Gem::Requirement
78
98
  requirements:
79
99
  - - "~>"
80
100
  - !ruby/object:Gem::Version
81
- version: '2.23'
101
+ version: '2.30'
82
102
  type: :runtime
83
103
  prerelease: false
84
104
  version_requirements: !ruby/object:Gem::Requirement
85
105
  requirements:
86
106
  - - "~>"
87
107
  - !ruby/object:Gem::Version
88
- version: '2.23'
108
+ version: '2.30'
89
109
  - !ruby/object:Gem::Dependency
90
110
  name: rubocop-rake
91
111
  requirement: !ruby/object:Gem::Requirement
92
112
  requirements:
93
113
  - - "~>"
94
114
  - !ruby/object:Gem::Version
95
- version: '0.6'
115
+ version: '0.7'
116
+ - - ">="
117
+ - !ruby/object:Gem::Version
118
+ version: 0.7.1
96
119
  type: :runtime
97
120
  prerelease: false
98
121
  version_requirements: !ruby/object:Gem::Requirement
99
122
  requirements:
100
123
  - - "~>"
101
124
  - !ruby/object:Gem::Version
102
- version: '0.6'
125
+ version: '0.7'
126
+ - - ">="
127
+ - !ruby/object:Gem::Version
128
+ version: 0.7.1
103
129
  - !ruby/object:Gem::Dependency
104
130
  name: rubocop-rspec
105
131
  requirement: !ruby/object:Gem::Requirement
106
132
  requirements:
107
133
  - - "~>"
108
134
  - !ruby/object:Gem::Version
109
- version: '3.0'
110
- - - ">="
111
- - !ruby/object:Gem::Version
112
- version: 3.0.1
135
+ version: '3.5'
113
136
  type: :runtime
114
137
  prerelease: false
115
138
  version_requirements: !ruby/object:Gem::Requirement
116
139
  requirements:
117
140
  - - "~>"
118
141
  - !ruby/object:Gem::Version
119
- version: '3.0'
120
- - - ">="
121
- - !ruby/object:Gem::Version
122
- version: 3.0.1
142
+ version: '3.5'
123
143
  - !ruby/object:Gem::Dependency
124
144
  name: rubocop-rspec_rails
125
145
  requirement: !ruby/object:Gem::Requirement
@@ -159,15 +179,16 @@ files:
159
179
  - config/rubocop.yml
160
180
  - lib/rubocop-cargosense.rb
161
181
  - lib/rubocop/cargosense.rb
162
- - lib/rubocop/cargosense/inject.rb
182
+ - lib/rubocop/cargosense/plugin.rb
163
183
  homepage: https://github.com/CargoSense/rubocop-cargosense
164
184
  licenses:
165
185
  - MIT
166
186
  metadata:
167
187
  bug_tracker_uri: https://github.com/CargoSense/rubocop-cargosense/issues
168
188
  changelog_uri: https://github.com/CargoSense/rubocop-cargosense/releases
189
+ default_lint_roller_plugin: RuboCop::CargoSense::Plugin
169
190
  rubygems_mfa_required: 'true'
170
- source_code_uri: https://github.com/CargoSense/rubocop-cargosense/tree/v4.0.0
191
+ source_code_uri: https://github.com/CargoSense/rubocop-cargosense/tree/v5.0.0
171
192
  post_install_message:
172
193
  rdoc_options: []
173
194
  require_paths:
@@ -1,16 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module RuboCop
4
- module CargoSense
5
- module Inject
6
- def self.defaults!
7
- path = CONFIG_DEFAULT.to_s
8
- hash = ConfigLoader.load_file(path)
9
- config = Config.new(hash, path).tap(&:make_excludes_absolute)
10
- puts "configuration from #{path}" if ConfigLoader.debug?
11
- config = ConfigLoader.merge_with_default(config, path, unset_nil: false)
12
- ConfigLoader.instance_variable_set(:@default_configuration, config)
13
- end
14
- end
15
- end
16
- end