nucop 0.5.0 → 0.6.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: 45f13be981ded202e5db52b7dfcfcfcd4102571f4484742f9eec254e49b67458
4
- data.tar.gz: d8d8c17450bac9ce256b252293fb9dac25f5224b56d9048da5a05c0023cb4dc6
3
+ metadata.gz: e71dbde954a64a032a66647897b9b1f6fbe958f59b5bbfd9de3fab916ec4c569
4
+ data.tar.gz: 772c10cf45fbc941e43697b48c1c0a6d22401b75555ee26a4d4fbba924dc50de
5
5
  SHA512:
6
- metadata.gz: c9a6d065bf3b6552007b13f0ba31a4f74b0ac2a6db722eb744bd0a915fa583a87c99c62981dba5057bb5808a917a37c7f03d2cd815a74af820ee8ea0b5cf5064
7
- data.tar.gz: 40f962753716b23da0e6f645b2c71bdc27cdd8999fe5ab60bd97053696a5710e82f2ebe60be162e5c55ca4de732b3845bcc56b0a959962fc51ece3c18805105f
6
+ metadata.gz: 12133cde2275ba413c18814d70c1025b39081f77ce2bedb9d13694d7818222b86b8943c2b33e2874b69543d6a4e6b5fc0828e3846471e2a30e3bba3b85926607
7
+ data.tar.gz: d1635fb6d929b0fad0e32d13a62d4ba7ef9692735deeebfecb657a98402c8c6de885617817565b7e7b4087ccdbe8a3d1a6b0fb935e54f8b59c3473699ade7526
data/lib/nucop/cli.rb CHANGED
@@ -108,7 +108,7 @@ module Nucop
108
108
  desc "modified_lines", "display RuboCop violations for ONLY modified lines"
109
109
  method_option "commit-spec", default: "main", desc: "the commit used to determine the diff."
110
110
  def modified_lines
111
- diff_files, diff_status = Open3.capture2("git diff #{options[:'commit-spec']} --diff-filter=d --name-only | grep \"\\.rb$\"")
111
+ diff_files, diff_status = Open3.capture2("git diff #{options[:"commit-spec"]} --diff-filter=d --name-only | grep \"\\.rb$\"")
112
112
 
113
113
  exit 1 unless diff_status.exitstatus.zero?
114
114
 
@@ -209,10 +209,14 @@ module Nucop
209
209
  rubocop_options = [
210
210
  "--auto-gen-config",
211
211
  "--config #{options[:rubocop_todo_config_file]}",
212
- "--exclude-limit #{options[:'exclude-limit']}",
213
- "--require rubocop-rspec",
212
+ "--exclude-limit #{options[:"exclude-limit"]}",
213
+ "--require rubocop-graphql",
214
214
  "--require rubocop-performance",
215
- "--require rubocop-rails"
215
+ "--require rubocop-rails",
216
+ "--require rubocop-rake",
217
+ "--require rubocop-rspec",
218
+ "--require rubocop-rubycw",
219
+ "--require rubocop-thread_safety"
216
220
  ]
217
221
 
218
222
  rubocop_command = "DISABLE_SPRING=1 bundle exec rubocop #{rubocop_options.join(' ')}"
@@ -234,9 +238,7 @@ module Nucop
234
238
  end
235
239
 
236
240
  if current_enforced_cops.cop_added?
237
- File.open(options[:enforced_cops_file], "w+") do |f|
238
- f.write(current_enforced_cops.to_a.sort.to_yaml)
239
- end
241
+ File.write(options[:enforced_cops_file], current_enforced_cops.to_a.sort.to_yaml)
240
242
  puts "Updated '#{options[:enforced_cops_file]}'!"
241
243
  else
242
244
  puts "No new cops are clear of violations"
@@ -29,7 +29,7 @@ module Nucop
29
29
  private
30
30
 
31
31
  def populate_history_from_git
32
- commit_spec = ENV["RUBOCOP_COMMIT_SPEC"] || "main"
32
+ commit_spec = ENV.fetch("RUBOCOP_COMMIT_SPEC", "main")
33
33
 
34
34
  diff = `git --no-pager diff #{commit_spec}`
35
35
 
data/lib/nucop/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Nucop
2
- VERSION = "0.5.0"
2
+ VERSION = "0.6.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nucop
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jason Schweier
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-12-06 00:00:00.000000000 Z
11
+ date: 2022-06-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: git_diff_parser
@@ -30,56 +30,56 @@ dependencies:
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '1.23'
33
+ version: '1.30'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: '1.23'
40
+ version: '1.30'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rubocop-graphql
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: '0.11'
47
+ version: '0.14'
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: '0.11'
54
+ version: '0.14'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: rubocop-performance
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: '1.12'
61
+ version: '1.14'
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
- version: '1.12'
68
+ version: '1.14'
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: rubocop-rails
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
73
  - - "~>"
74
74
  - !ruby/object:Gem::Version
75
- version: '2.12'
75
+ version: '2.15'
76
76
  type: :runtime
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
80
  - - "~>"
81
81
  - !ruby/object:Gem::Version
82
- version: '2.12'
82
+ version: '2.15'
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: rubocop-rake
85
85
  requirement: !ruby/object:Gem::Requirement
@@ -100,14 +100,42 @@ dependencies:
100
100
  requirements:
101
101
  - - "~>"
102
102
  - !ruby/object:Gem::Version
103
- version: '2.6'
103
+ version: '2.11'
104
104
  type: :runtime
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
108
  - - "~>"
109
109
  - !ruby/object:Gem::Version
110
- version: '2.6'
110
+ version: '2.11'
111
+ - !ruby/object:Gem::Dependency
112
+ name: rubocop-rubycw
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - "~>"
116
+ - !ruby/object:Gem::Version
117
+ version: '0.1'
118
+ type: :runtime
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - "~>"
123
+ - !ruby/object:Gem::Version
124
+ version: '0.1'
125
+ - !ruby/object:Gem::Dependency
126
+ name: rubocop-thread_safety
127
+ requirement: !ruby/object:Gem::Requirement
128
+ requirements:
129
+ - - "~>"
130
+ - !ruby/object:Gem::Version
131
+ version: '0.4'
132
+ type: :runtime
133
+ prerelease: false
134
+ version_requirements: !ruby/object:Gem::Requirement
135
+ requirements:
136
+ - - "~>"
137
+ - !ruby/object:Gem::Version
138
+ version: '0.4'
111
139
  - !ruby/object:Gem::Dependency
112
140
  name: ruby-progressbar
113
141
  requirement: !ruby/object:Gem::Requirement
@@ -142,14 +170,14 @@ dependencies:
142
170
  requirements:
143
171
  - - "~>"
144
172
  - !ruby/object:Gem::Version
145
- version: '3.10'
173
+ version: '3.11'
146
174
  type: :development
147
175
  prerelease: false
148
176
  version_requirements: !ruby/object:Gem::Requirement
149
177
  requirements:
150
178
  - - "~>"
151
179
  - !ruby/object:Gem::Version
152
- version: '3.10'
180
+ version: '3.11'
153
181
  description:
154
182
  email:
155
183
  - jasons@nulogy.com
@@ -175,7 +203,6 @@ files:
175
203
  - lib/nucop/helpers/file_path_helper.rb
176
204
  - lib/nucop/helpers/next_cop_for_promotion.rb
177
205
  - lib/nucop/version.rb
178
- - spec/spec_helper.rb
179
206
  homepage: https://rubygems.org/gems/nucop
180
207
  licenses:
181
208
  - MIT
@@ -199,10 +226,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
199
226
  - !ruby/object:Gem::Version
200
227
  version: '0'
201
228
  requirements: []
202
- rubygems_version: 3.1.6
229
+ rubygems_version: 3.3.15
203
230
  signing_key:
204
231
  specification_version: 4
205
232
  summary: Nulogy's implementation of RuboCop, including custom cops and additional
206
233
  tooling.
207
- test_files:
208
- - spec/spec_helper.rb
234
+ test_files: []
data/spec/spec_helper.rb DELETED
@@ -1,14 +0,0 @@
1
- require "bundler/setup"
2
- require "nucop"
3
-
4
- RSpec.configure do |config|
5
- # Enable flags like --only-failures and --next-failure
6
- config.example_status_persistence_file_path = ".rspec_status"
7
-
8
- # Disable RSpec exposing methods globally on `Module` and `main`
9
- config.disable_monkey_patching!
10
-
11
- config.expect_with(:rspec) do |c|
12
- c.syntax = :expect
13
- end
14
- end