google-style 1.26.4 → 1.27.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: 9988de3d9ba9027f65ccacdbb83f8f439e7fbdb013b3583c27c1c15b2dfe2e90
4
- data.tar.gz: f44bccefee149e40b795f7fd9cdf746eceaf90039f2300da4bbc84a48cdaa1ef
3
+ metadata.gz: 58a49ab0c0da9f69e6d6ddd9c41f6b3c68e38c1cbca9e6779afc3c7e9e076788
4
+ data.tar.gz: 8696d4e76014ab0319a17570fad4d3bf39b4cc93e71e1dde5d9e5f57b70be2cb
5
5
  SHA512:
6
- metadata.gz: 4f69177f59835eb77cbeab6f63054e7a87736bdd378d142195806c885124ac1eac3d20fcaac6ff6642dd90d61bb0d42c94687603e5488cd16c8b978cd5264df3
7
- data.tar.gz: 4a32c93a2cd38444c5243aff9ebb1289f86552097ad81cea519d31a3039e330f45f82955bf2310743397341908842da51c0ce6f0176a25c04593a39ac24d7643
6
+ metadata.gz: 7d16ac0ac6c7603dacfc3c215e2234f2811cc09ae05b2cad5339549ed284f06ce806c2ec620e385fdb9cbdd08131775079462a7405f8ddef180af8cfe5e63118
7
+ data.tar.gz: 0e84cc6d4f5fa48cea843efd4568b2dc8e6743447c1887aa905d60293d7ed51cdc7611d519583bea98639f6adb73424f7ea52f843d8b7a2ec98fafe05267989b
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
 
@@ -224,10 +256,26 @@ Style/CaseEquality:
224
256
  Style/CollectionCompact:
225
257
  Enabled: true
226
258
 
259
+ # Added in Rubocop 1.44
260
+ Style/ComparableClamp:
261
+ Enabled: true
262
+
263
+ # Added in Rubocop 1.41
264
+ Style/ConcatArrayLiterals:
265
+ Enabled: true
266
+
267
+ # Added in Rubocop 1.48
268
+ Style/DirEmpty:
269
+ Enabled: true
270
+
227
271
  # Added in Rubocop 1.1
228
272
  Style/DocumentDynamicEvalDefinition:
229
273
  Enabled: true
230
274
 
275
+ # Added in Rubocop 1.32
276
+ Style/EmptyHeredoc:
277
+ Enabled: true
278
+
231
279
  # We prefer consistent method indentation.
232
280
  Style/EmptyMethod:
233
281
  EnforcedStyle: expanded
@@ -240,10 +288,18 @@ Style/EndlessMethod:
240
288
  Style/EnvHome:
241
289
  Enabled: true
242
290
 
291
+ # Added in Rubocop 1.51
292
+ Style/ExactRegexpMatch:
293
+ Enabled: true
294
+
243
295
  # This check is overly paranoid.
244
296
  Style/FetchEnvVar:
245
297
  Enabled: false
246
298
 
299
+ # Added in Rubocop 1.48
300
+ Style/FileEmpty:
301
+ Enabled: true
302
+
247
303
  # Added in Rubocop 1.24
248
304
  Style/FileRead:
249
305
  Enabled: true
@@ -277,6 +333,10 @@ Style/IfWithBooleanLiteralBranches:
277
333
  Style/InPatternThen:
278
334
  Enabled: true
279
335
 
336
+ # Added in Rubocop 1.35
337
+ Style/MagicCommentFormat:
338
+ Enabled: true
339
+
280
340
  # Added in Rubocop 1.30
281
341
  Style/MapCompactWithConditionalBlock:
282
342
  Enabled: true
@@ -285,6 +345,10 @@ Style/MapCompactWithConditionalBlock:
285
345
  Style/MapToHash:
286
346
  Enabled: true
287
347
 
348
+ # Added in Rubocop 1.42
349
+ Style/MapToSet:
350
+ Enabled: true
351
+
288
352
  # We adopt Seattle-style paren usage
289
353
  Style/MethodCallWithArgsParentheses:
290
354
  AllowParenthesesInCamelCaseMethod: true
@@ -297,6 +361,11 @@ Style/MethodCallWithArgsParentheses:
297
361
  Style/MethodDefParentheses:
298
362
  EnforcedStyle: require_no_parentheses
299
363
 
364
+ # I (dazuma@) am not a fan of this rule. It's a bit more readable but at the
365
+ # cost of being logically clever.
366
+ Style/MinMaxComparison:
367
+ Enabled: false
368
+
300
369
  # Enable use of the different semantics of module_function and extend self.
301
370
  Style/ModuleFunction:
302
371
  Enabled: false
@@ -305,6 +374,11 @@ Style/ModuleFunction:
305
374
  Style/MultilineInPatternThen:
306
375
  Enabled: true
307
376
 
377
+ # I (dazuma@) am not a fan of this rule. Its readability benefit is debatable
378
+ # and it carries the cost of being logically clever.
379
+ Style/MultipleComparison:
380
+ Enabled: false
381
+
308
382
  # Added in Rubocop 1.2
309
383
  Style/NegatedIfElseCondition:
310
384
  Enabled: true
@@ -338,6 +412,11 @@ Style/OpenStructUse:
338
412
  - "acceptance/**/*.rb"
339
413
  - "samples/acceptance/**/*.rb"
340
414
 
415
+ # Added in Rubocop 1.37. Open to disabling this if it causes problems for
416
+ # metaprogramming-heavy code.
417
+ Style/OperatorMethodCall:
418
+ Enabled: true
419
+
341
420
  # Added in Rubocop 1.16
342
421
  Style/QuotedSymbols:
343
422
  Enabled: true
@@ -346,19 +425,64 @@ Style/QuotedSymbols:
346
425
  Style/RedundantArgument:
347
426
  Enabled: true
348
427
 
428
+ # Added in Rubocop 1.52
429
+ Style/RedundantArrayConstructor:
430
+ Enabled: true
431
+
349
432
  # Disabled because we prefer to keep begin-end blocks in memoization for
350
433
  # readability (see https://github.com/rubocop/rubocop/pull/9602).
351
434
  Style/RedundantBegin:
352
435
  Enabled: false
353
436
 
437
+ # Disabled because we believe it's good practice to be explicit about constant
438
+ # namespaces, given how confusing constant lookup rules are in Ruby.
439
+ Style/RedundantConstantBase:
440
+ Enabled: false
441
+
442
+ # Added in Rubocop 1.53
443
+ Style/RedundantCurrentDirectoryInPath:
444
+ Enabled: true
445
+
446
+ # Added in Rubocop 1.41
447
+ Style/RedundantDoubleSplatHashBraces:
448
+ Enabled: true
449
+
450
+ # Added in Rubocop 1.38
451
+ Style/RedundantEach:
452
+ Enabled: true
453
+
454
+ # Added in Rubocop 1.52
455
+ Style/RedundantFilterChain:
456
+ Enabled: true
457
+
458
+ # Added in Rubocop 1.45
459
+ Style/RedundantHeredocDelimiterQuotes:
460
+ Enabled: true
461
+
354
462
  # Added in Rubocop 1.27
355
463
  Style/RedundantInitialize:
356
464
  Enabled: true
357
465
 
466
+ # Added in Rubocop 1.49
467
+ Style/RedundantLineContinuation:
468
+ Enabled: true
469
+
470
+ # Added in Rubocop 1.53
471
+ Style/RedundantRegexpArgument:
472
+ Enabled: true
473
+
474
+ # Added in Rubocop 1.52
475
+ Style/RedundantRegexpConstructor:
476
+ Enabled: true
477
+
358
478
  # Added in Rubocop 1.19
359
479
  Style/RedundantSelfAssignmentBranch:
360
480
  Enabled: true
361
481
 
482
+ # Added in Rubocop 1.37
483
+ Style/RedundantStringEscape:
484
+ Enabled: true
485
+
362
486
  # Disabled because we find it to be pedantic. The enforced rules are too simple
363
487
  # to capture readability, and are especially problematic for generated code.
364
488
  Style/RegexpLiteral:
@@ -368,6 +492,10 @@ Style/RegexpLiteral:
368
492
  Style/RescueModifier:
369
493
  Enabled: false
370
494
 
495
+ # Added in Rubocop 1.53. Open to disabling, since there may be exceptions.
496
+ Style/ReturnNilInPredicateMethodDefinition:
497
+ Enabled: true
498
+
371
499
  # We disagree with this one. Grep is more specialized than select/reject.
372
500
  Style/SelectByRegexp:
373
501
  Enabled: false
@@ -395,3 +523,7 @@ Style/TrivialAccessors:
395
523
  # We prefer traditional bracket style for all arrays.
396
524
  Style/WordArray:
397
525
  EnforcedStyle: brackets
526
+
527
+ # Added in Rubocop 1.53
528
+ Style/YAMLFileRead:
529
+ 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.0"
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.0
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: 2023-09-13 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.4.19
62
+ signing_key:
63
63
  specification_version: 4
64
64
  summary: Collection of rubocop rules
65
65
  test_files: []