google-style 1.26.4 → 1.27.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9988de3d9ba9027f65ccacdbb83f8f439e7fbdb013b3583c27c1c15b2dfe2e90
4
- data.tar.gz: f44bccefee149e40b795f7fd9cdf746eceaf90039f2300da4bbc84a48cdaa1ef
3
+ metadata.gz: 87007242fed89be89a436b81be70abd484e4f537c6a565c4150adfb0bb6552ed
4
+ data.tar.gz: f7e4172dba6edaa4072a9f40c33d4fefc5e1c89c1e4d9308411ec2db51c80cd4
5
5
  SHA512:
6
- metadata.gz: 4f69177f59835eb77cbeab6f63054e7a87736bdd378d142195806c885124ac1eac3d20fcaac6ff6642dd90d61bb0d42c94687603e5488cd16c8b978cd5264df3
7
- data.tar.gz: 4a32c93a2cd38444c5243aff9ebb1289f86552097ad81cea519d31a3039e330f45f82955bf2310743397341908842da51c0ce6f0176a25c04593a39ac24d7643
6
+ metadata.gz: f25a2ec00e086296c7e9e8c99e89ee94a8add0697baef9d1e43b3d531c3e217d38cb4416ebd222c2275827a4cf443efd17405ad720a18cb0b25f98917d5e3633
7
+ data.tar.gz: 94682d1ae0e65c8528f650f1192e55992b468523769c79ca7e8293f108d061e5abb08d1f521816ebc82e90961184a1d2c399ec2a576f58d5915f76cca190f984
data/README.md CHANGED
@@ -47,12 +47,12 @@ specific minor version.
47
47
 
48
48
  Contributions to this library are always welcome and highly encouraged.
49
49
 
50
- See the [Contributing Guide](CONTRIBUTING.md)
50
+ See the {file:CONTRIBUTING.md Contributing Guide}
51
51
  for more information on how to get started.
52
52
 
53
53
  Please note that this project is released with a Contributor Code of Conduct. By
54
- participating in this project you agree to abide by its terms. See the [Code of
55
- Conduct](CODE_OF_CONDUCT.md) for more information.
54
+ participating in this project you agree to abide by its terms. See the {file:CODE_OF_CONDUCT.md Code of
55
+ Conduct} for more information.
56
56
 
57
57
  ## License
58
58
 
data/google-style.yml CHANGED
@@ -15,12 +15,16 @@
15
15
  AllCops:
16
16
  NewCops: disable
17
17
  SuggestExtensions: false
18
- TargetRubyVersion: 2.6
18
+ TargetRubyVersion: 2.7
19
19
 
20
20
  # Added in Rubocop 1.30
21
21
  Gemspec/DeprecatedAttributeAssignment:
22
22
  Enabled: true
23
23
 
24
+ # Added in Rubocop 1.44
25
+ Gemspec/DevelopmentDependencies:
26
+ Enabled: true
27
+
24
28
  # Disabled for now.
25
29
  Gemspec/RequireMFA:
26
30
  Enabled: false
@@ -88,6 +92,14 @@ Lint/DeprecatedConstants:
88
92
  Lint/DuplicateBranch:
89
93
  Enabled: true
90
94
 
95
+ # Added in Rubocop 1.37
96
+ Lint/DuplicateMagicComment:
97
+ Enabled: true
98
+
99
+ # Added in Rubocop 1.50
100
+ Lint/DuplicateMatchPattern:
101
+ Enabled: true
102
+
91
103
  # Added in Rubocop 1.1
92
104
  Lint/DuplicateRegexpCharacterClassElement:
93
105
  Enabled: true
@@ -112,6 +124,10 @@ Lint/IncompatibleIoSelectWithFiberScheduler:
112
124
  Lint/LambdaWithoutLiteralBlock:
113
125
  Enabled: true
114
126
 
127
+ # Added in Rubocop 1.53
128
+ Lint/MixedCaseRange:
129
+ Enabled: true
130
+
115
131
  # Added in Rubocop 1.2
116
132
  Lint/NoReturnInBeginEndBlocks:
117
133
  Enabled: true
@@ -132,10 +148,18 @@ Lint/OrAssignmentToConstant:
132
148
  Lint/RedundantDirGlobSort:
133
149
  Enabled: true
134
150
 
151
+ # Added in Rubocop 1.53
152
+ Lint/RedundantRegexpQuantifiers:
153
+ Enabled: true
154
+
135
155
  # Added in Rubocop 1.27
136
156
  Lint/RefinementImportMethods:
137
157
  Enabled: true
138
158
 
159
+ # Added in Rubocop 1.32
160
+ Lint/RequireRangeParentheses:
161
+ Enabled: true
162
+
139
163
  # Added in Rubocop 1.22
140
164
  Lint/RequireRelativeSelfPath:
141
165
  Enabled: true
@@ -160,6 +184,10 @@ Lint/UnexpectedBlockArity:
160
184
  Lint/UnmodifiedReduceAccumulator:
161
185
  Enabled: true
162
186
 
187
+ # Added in Rubocop 1.43
188
+ Lint/UselessRescue:
189
+ Enabled: true
190
+
163
191
  # Added in Rubocop 1.23
164
192
  Lint/UselessRuby2Keywords:
165
193
  Enabled: true
@@ -167,6 +195,10 @@ Lint/UselessRuby2Keywords:
167
195
  Metrics/AbcSize:
168
196
  Max: 30
169
197
 
198
+ # Could be problematic for generated code, and overall not very useful.
199
+ Metrics/CollectionLiteralLength:
200
+ Enabled: false
201
+
170
202
  Metrics/CyclomaticComplexity:
171
203
  Max: 10
172
204
 
@@ -210,6 +242,10 @@ Style/AccessorGrouping:
210
242
  # Added in Rubocop 1.1
211
243
  Style/ArgumentsForwarding:
212
244
  Enabled: true
245
+ RedundantBlockArgumentNames: [] # To support Ruby < 3.2
246
+ RedundantKeywordRestArgumentNames: [] # To support Ruby < 3.2
247
+ RedundantRestArgumentNames: [] # To support Ruby < 3.2
248
+ UseAnonymousForwarding: false # To support Ruby < 3.2
213
249
 
214
250
  # Problematic for generated code which might include unicode in comments.
215
251
  Style/AsciiComments:
@@ -224,10 +260,26 @@ Style/CaseEquality:
224
260
  Style/CollectionCompact:
225
261
  Enabled: true
226
262
 
263
+ # Added in Rubocop 1.44
264
+ Style/ComparableClamp:
265
+ Enabled: true
266
+
267
+ # Added in Rubocop 1.41
268
+ Style/ConcatArrayLiterals:
269
+ Enabled: true
270
+
271
+ # Added in Rubocop 1.48
272
+ Style/DirEmpty:
273
+ Enabled: true
274
+
227
275
  # Added in Rubocop 1.1
228
276
  Style/DocumentDynamicEvalDefinition:
229
277
  Enabled: true
230
278
 
279
+ # Added in Rubocop 1.32
280
+ Style/EmptyHeredoc:
281
+ Enabled: true
282
+
231
283
  # We prefer consistent method indentation.
232
284
  Style/EmptyMethod:
233
285
  EnforcedStyle: expanded
@@ -240,10 +292,18 @@ Style/EndlessMethod:
240
292
  Style/EnvHome:
241
293
  Enabled: true
242
294
 
295
+ # Added in Rubocop 1.51
296
+ Style/ExactRegexpMatch:
297
+ Enabled: true
298
+
243
299
  # This check is overly paranoid.
244
300
  Style/FetchEnvVar:
245
301
  Enabled: false
246
302
 
303
+ # Added in Rubocop 1.48
304
+ Style/FileEmpty:
305
+ Enabled: true
306
+
247
307
  # Added in Rubocop 1.24
248
308
  Style/FileRead:
249
309
  Enabled: true
@@ -277,6 +337,10 @@ Style/IfWithBooleanLiteralBranches:
277
337
  Style/InPatternThen:
278
338
  Enabled: true
279
339
 
340
+ # Added in Rubocop 1.35
341
+ Style/MagicCommentFormat:
342
+ Enabled: true
343
+
280
344
  # Added in Rubocop 1.30
281
345
  Style/MapCompactWithConditionalBlock:
282
346
  Enabled: true
@@ -285,6 +349,10 @@ Style/MapCompactWithConditionalBlock:
285
349
  Style/MapToHash:
286
350
  Enabled: true
287
351
 
352
+ # Added in Rubocop 1.42
353
+ Style/MapToSet:
354
+ Enabled: true
355
+
288
356
  # We adopt Seattle-style paren usage
289
357
  Style/MethodCallWithArgsParentheses:
290
358
  AllowParenthesesInCamelCaseMethod: true
@@ -297,6 +365,11 @@ Style/MethodCallWithArgsParentheses:
297
365
  Style/MethodDefParentheses:
298
366
  EnforcedStyle: require_no_parentheses
299
367
 
368
+ # I (dazuma@) am not a fan of this rule. It's a bit more readable but at the
369
+ # cost of being logically clever.
370
+ Style/MinMaxComparison:
371
+ Enabled: false
372
+
300
373
  # Enable use of the different semantics of module_function and extend self.
301
374
  Style/ModuleFunction:
302
375
  Enabled: false
@@ -305,6 +378,11 @@ Style/ModuleFunction:
305
378
  Style/MultilineInPatternThen:
306
379
  Enabled: true
307
380
 
381
+ # I (dazuma@) am not a fan of this rule. Its readability benefit is debatable
382
+ # and it carries the cost of being logically clever.
383
+ Style/MultipleComparison:
384
+ Enabled: false
385
+
308
386
  # Added in Rubocop 1.2
309
387
  Style/NegatedIfElseCondition:
310
388
  Enabled: true
@@ -338,6 +416,11 @@ Style/OpenStructUse:
338
416
  - "acceptance/**/*.rb"
339
417
  - "samples/acceptance/**/*.rb"
340
418
 
419
+ # Added in Rubocop 1.37. Open to disabling this if it causes problems for
420
+ # metaprogramming-heavy code.
421
+ Style/OperatorMethodCall:
422
+ Enabled: true
423
+
341
424
  # Added in Rubocop 1.16
342
425
  Style/QuotedSymbols:
343
426
  Enabled: true
@@ -346,19 +429,64 @@ Style/QuotedSymbols:
346
429
  Style/RedundantArgument:
347
430
  Enabled: true
348
431
 
432
+ # Added in Rubocop 1.52
433
+ Style/RedundantArrayConstructor:
434
+ Enabled: true
435
+
349
436
  # Disabled because we prefer to keep begin-end blocks in memoization for
350
437
  # readability (see https://github.com/rubocop/rubocop/pull/9602).
351
438
  Style/RedundantBegin:
352
439
  Enabled: false
353
440
 
441
+ # Disabled because we believe it's good practice to be explicit about constant
442
+ # namespaces, given how confusing constant lookup rules are in Ruby.
443
+ Style/RedundantConstantBase:
444
+ Enabled: false
445
+
446
+ # Added in Rubocop 1.53
447
+ Style/RedundantCurrentDirectoryInPath:
448
+ Enabled: true
449
+
450
+ # Added in Rubocop 1.41
451
+ Style/RedundantDoubleSplatHashBraces:
452
+ Enabled: true
453
+
454
+ # Added in Rubocop 1.38
455
+ Style/RedundantEach:
456
+ Enabled: true
457
+
458
+ # Added in Rubocop 1.52
459
+ Style/RedundantFilterChain:
460
+ Enabled: true
461
+
462
+ # Added in Rubocop 1.45
463
+ Style/RedundantHeredocDelimiterQuotes:
464
+ Enabled: true
465
+
354
466
  # Added in Rubocop 1.27
355
467
  Style/RedundantInitialize:
356
468
  Enabled: true
357
469
 
470
+ # Added in Rubocop 1.49
471
+ Style/RedundantLineContinuation:
472
+ Enabled: true
473
+
474
+ # Added in Rubocop 1.53
475
+ Style/RedundantRegexpArgument:
476
+ Enabled: true
477
+
478
+ # Added in Rubocop 1.52
479
+ Style/RedundantRegexpConstructor:
480
+ Enabled: true
481
+
358
482
  # Added in Rubocop 1.19
359
483
  Style/RedundantSelfAssignmentBranch:
360
484
  Enabled: true
361
485
 
486
+ # Added in Rubocop 1.37
487
+ Style/RedundantStringEscape:
488
+ Enabled: true
489
+
362
490
  # Disabled because we find it to be pedantic. The enforced rules are too simple
363
491
  # to capture readability, and are especially problematic for generated code.
364
492
  Style/RegexpLiteral:
@@ -368,6 +496,10 @@ Style/RegexpLiteral:
368
496
  Style/RescueModifier:
369
497
  Enabled: false
370
498
 
499
+ # Added in Rubocop 1.53. Open to disabling, since there may be exceptions.
500
+ Style/ReturnNilInPredicateMethodDefinition:
501
+ Enabled: true
502
+
371
503
  # We disagree with this one. Grep is more specialized than select/reject.
372
504
  Style/SelectByRegexp:
373
505
  Enabled: false
@@ -395,3 +527,7 @@ Style/TrivialAccessors:
395
527
  # We prefer traditional bracket style for all arrays.
396
528
  Style/WordArray:
397
529
  EnforcedStyle: brackets
530
+
531
+ # Added in Rubocop 1.53
532
+ Style/YAMLFileRead:
533
+ Enabled: true
@@ -16,6 +16,6 @@
16
16
 
17
17
  module Google
18
18
  module Style
19
- VERSION = "1.26.4"
19
+ VERSION = "1.27.1"
20
20
  end
21
21
  end
metadata CHANGED
@@ -1,15 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-style
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.26.4
4
+ version: 1.27.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Azuma
8
8
  - Graham Paye
9
- autorequire:
9
+ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2023-12-03 00:00:00.000000000 Z
12
+ date: 2024-01-20 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rubocop
@@ -17,14 +17,14 @@ dependencies:
17
17
  requirements:
18
18
  - - "~>"
19
19
  - !ruby/object:Gem::Version
20
- version: 1.57.2
20
+ version: '1.56'
21
21
  type: :runtime
22
22
  prerelease: false
23
23
  version_requirements: !ruby/object:Gem::Requirement
24
24
  requirements:
25
25
  - - "~>"
26
26
  - !ruby/object:Gem::Version
27
- version: 1.57.2
27
+ version: '1.56'
28
28
  description: Shared style guide for Google's ruby projects
29
29
  email:
30
30
  - dazuma@google.com
@@ -43,7 +43,7 @@ homepage: https://github.com/googleapis/ruby-style/
43
43
  licenses:
44
44
  - Apache-2.0
45
45
  metadata: {}
46
- post_install_message:
46
+ post_install_message:
47
47
  rdoc_options: []
48
48
  require_paths:
49
49
  - lib
@@ -51,15 +51,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - ">="
53
53
  - !ruby/object:Gem::Version
54
- version: 2.6.0
54
+ version: 2.7.0
55
55
  required_rubygems_version: !ruby/object:Gem::Requirement
56
56
  requirements:
57
57
  - - ">="
58
58
  - !ruby/object:Gem::Version
59
59
  version: '0'
60
60
  requirements: []
61
- rubygems_version: 3.4.10
62
- signing_key:
61
+ rubygems_version: 3.5.3
62
+ signing_key:
63
63
  specification_version: 4
64
64
  summary: Collection of rubocop rules
65
65
  test_files: []