ribose 0.3.1 → 0.5.0

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: b7c4b6c53a6c8d7f9a5648e1aa4cb0bf8e37ffa9cac3d9d1fecd5c6fbbc1c81a
4
- data.tar.gz: 3a8eaac73e14e834ce155b3e2ca1c4ac1593d0925ad26dc61085c0a570f0883e
3
+ metadata.gz: 5b5cd9ec9c1ad48a6f57f72e1cdc8e09b7eb3213a7eeb28bd242996f49c8d053
4
+ data.tar.gz: ba146ea565546ea00f3f508626e83400cefd7552d59ba94f3119cb702a75067f
5
5
  SHA512:
6
- metadata.gz: 1fe42b371ab20c599bc152089f439aebd1ad02c5e04dccdef71b64e5b353b3c88984dfe2d4b088ebe5d75e27d54d6ebc433dae3ebadfc5531abe9167a21c79c4
7
- data.tar.gz: a6dd3241989f1499e3ee48710f8118eeafc886f4716cf3e59ef75a128eec2ae057073d7a5f39f23749744da25aa334b927afbdcabfd1991c50572a557f7b872f
6
+ metadata.gz: 6e9ba0061275f1f6f83e72f2f1f9ca9b2c8310bfd17ba7aabbe9baeab5de271d3d4570c92bb00675f2961e2c08c4c29236044641edff208ad7af1babfbb34eae
7
+ data.tar.gz: 40b4ac4817cfc6e8c18a7624a39a461578dcc1e8f52392349e1ac4d6e44e0898bb2de0fc6c70eece64af6ced98e095bee0aba8d1697b7d9cc11359f303b45493
@@ -0,0 +1,27 @@
1
+ name: test
2
+
3
+ on:
4
+ push:
5
+ branches: [ main ]
6
+ tags: [ v* ]
7
+ pull_request:
8
+
9
+ jobs:
10
+ test:
11
+ name: RSpec
12
+ runs-on: ${{ matrix.os }}
13
+ strategy:
14
+ fail-fast: false
15
+ matrix:
16
+ ruby: ['2.5', '2.6', '2.7', '3.0' ]
17
+ os: [ ubuntu-latest, windows-latest, macos-latest ]
18
+
19
+ steps:
20
+ - uses: actions/checkout@v2
21
+
22
+ - uses: ruby/setup-ruby@v1
23
+ with:
24
+ ruby-version: ${{ matrix.ruby }}
25
+ bundler-cache: true
26
+
27
+ - run: bundle exec rake
data/.rubocop.yml CHANGED
@@ -1,645 +1,10 @@
1
- AllCops:
2
- Include:
3
- - "**/*.rake"
4
- - "**/Gemfile"
5
- - "**/Rakefile"
6
-
7
- Exclude:
8
- - db/schema.rb
9
-
10
- Naming/AccessorMethodName:
11
- Description: Check the naming of accessor methods for get_/set_.
12
- Enabled: false
13
-
14
- Style/Alias:
15
- Description: 'Use alias_method instead of alias.'
16
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#alias-method'
17
- Enabled: false
18
-
19
- Style/ArrayJoin:
20
- Description: 'Use Array#join instead of Array#*.'
21
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#array-join'
22
- Enabled: false
23
-
24
- Style/AsciiComments:
25
- Description: 'Use only ascii symbols in comments.'
26
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#english-comments'
27
- Enabled: false
28
-
29
- Naming/AsciiIdentifiers:
30
- Description: 'Use only ascii symbols in identifiers.'
31
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#english-identifiers'
32
- Enabled: false
33
-
34
- Style/Attr:
35
- Description: 'Checks for uses of Module#attr.'
36
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#attr'
37
- Enabled: false
38
-
39
- Metrics/BlockNesting:
40
- Description: 'Avoid excessive block nesting'
41
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#three-is-the-number-thou-shalt-count'
42
- Enabled: false
43
-
44
- Style/CaseEquality:
45
- Description: 'Avoid explicit use of the case equality operator(===).'
46
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-case-equality'
47
- Enabled: false
48
-
49
- Style/CharacterLiteral:
50
- Description: 'Checks for uses of character literals.'
51
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-character-literals'
52
- Enabled: false
53
-
54
- Style/ClassAndModuleChildren:
55
- Description: 'Checks style of children classes and modules.'
56
- Enabled: true
57
- EnforcedStyle: nested
58
-
59
- Metrics/ClassLength:
60
- Description: 'Avoid classes longer than 100 lines of code.'
61
- Enabled: false
62
-
63
- Metrics/ModuleLength:
64
- Description: 'Avoid modules longer than 100 lines of code.'
65
- Enabled: false
66
-
67
- Style/ClassVars:
68
- Description: 'Avoid the use of class variables.'
69
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-class-vars'
70
- Enabled: false
71
-
72
- Style/CollectionMethods:
73
- Enabled: true
74
- PreferredMethods:
75
- find: detect
76
- inject: reduce
77
- collect: map
78
- find_all: select
79
-
80
- Style/ColonMethodCall:
81
- Description: 'Do not use :: for method call.'
82
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#double-colons'
83
- Enabled: false
84
-
85
- Style/CommentAnnotation:
86
- Description: >-
87
- Checks formatting of special comments
88
- (TODO, FIXME, OPTIMIZE, HACK, REVIEW).
89
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#annotate-keywords'
90
- Enabled: false
91
-
92
- Metrics/AbcSize:
93
- Description: >-
94
- A calculated magnitude based on number of assignments,
95
- branches, and conditions.
96
- Enabled: false
97
-
98
- Metrics/BlockLength:
99
- CountComments: true # count full line comments?
100
- Max: 25
101
- ExcludedMethods: []
102
- Exclude:
103
- - "spec/**/*"
104
-
105
- Metrics/CyclomaticComplexity:
106
- Description: >-
107
- A complexity metric that is strongly correlated to the number
108
- of test cases needed to validate a method.
109
- Enabled: false
110
-
111
- Rails/Delegate:
112
- Description: 'Prefer delegate method for delegations.'
113
- Enabled: false
114
-
115
- Style/PreferredHashMethods:
116
- Description: 'Checks use of `has_key?` and `has_value?` Hash methods.'
117
- StyleGuide: '#hash-key'
118
- Enabled: false
119
-
120
- Style/Documentation:
121
- Description: 'Document classes and non-namespace modules.'
122
- Enabled: false
123
-
124
- Style/DoubleNegation:
125
- Description: 'Checks for uses of double negation (!!).'
126
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-bang-bang'
127
- Enabled: false
128
-
129
- Style/EachWithObject:
130
- Description: 'Prefer `each_with_object` over `inject` or `reduce`.'
131
- Enabled: false
132
-
133
- Style/EmptyLiteral:
134
- Description: 'Prefer literals to Array.new/Hash.new/String.new.'
135
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#literal-array-hash'
136
- Enabled: false
137
-
138
- # Checks whether the source file has a utf-8 encoding comment or not
139
- # AutoCorrectEncodingComment must match the regex
140
- # /#.*coding\s?[:=]\s?(?:UTF|utf)-8/
141
- Style/Encoding:
142
- Enabled: false
143
-
144
- Style/EvenOdd:
145
- Description: 'Favor the use of Fixnum#even? && Fixnum#odd?'
146
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#predicate-methods'
147
- Enabled: false
148
-
149
- Naming/FileName:
150
- Description: 'Use snake_case for source file names.'
151
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#snake-case-files'
152
- Enabled: false
153
-
154
- Style/FrozenStringLiteralComment:
155
- Description: >-
156
- Add the frozen_string_literal comment to the top of files
157
- to help transition from Ruby 2.3.0 to Ruby 3.0.
158
- Enabled: false
159
-
160
- Style/FlipFlop:
161
- Description: 'Checks for flip flops'
162
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-flip-flops'
163
- Enabled: false
164
-
165
- Style/FormatString:
166
- Description: 'Enforce the use of Kernel#sprintf, Kernel#format or String#%.'
167
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#sprintf'
168
- Enabled: false
169
-
170
- Style/GlobalVars:
171
- Description: 'Do not introduce global variables.'
172
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#instance-vars'
173
- Reference: 'http://www.zenspider.com/Languages/Ruby/QuickRef.html'
174
- Enabled: false
175
-
176
- Style/GuardClause:
177
- Description: 'Check for conditionals that can be replaced with guard clauses'
178
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-nested-conditionals'
179
- Enabled: false
180
-
181
- Style/IfUnlessModifier:
182
- Description: >-
183
- Favor modifier if/unless usage when you have a
184
- single-line body.
185
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#if-as-a-modifier'
186
- Enabled: false
187
-
188
- Style/IfWithSemicolon:
189
- Description: 'Do not use if x; .... Use the ternary operator instead.'
190
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-semicolon-ifs'
191
- Enabled: false
192
-
193
- Style/InlineComment:
194
- Description: 'Avoid inline comments.'
195
- Enabled: false
196
-
197
- Style/Lambda:
198
- Description: 'Use the new lambda literal syntax for single-line blocks.'
199
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#lambda-multi-line'
200
- Enabled: false
201
-
202
- Style/LambdaCall:
203
- Description: 'Use lambda.call(...) instead of lambda.(...).'
204
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#proc-call'
205
- Enabled: false
206
-
207
- Style/LineEndConcatenation:
208
- Description: >-
209
- Use \ instead of + or << to concatenate two string literals at
210
- line end.
211
- Enabled: false
212
-
213
- Metrics/LineLength:
214
- Description: 'Limit lines to 80 characters.'
215
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#80-character-limits'
216
- Max: 80
217
-
218
- Metrics/MethodLength:
219
- Description: 'Avoid methods longer than 10 lines of code.'
220
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#short-methods'
221
- Enabled: false
222
-
223
- Style/ModuleFunction:
224
- Description: 'Checks for usage of `extend self` in modules.'
225
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#module-function'
226
- Enabled: false
227
-
228
- Style/MultilineBlockChain:
229
- Description: 'Avoid multi-line chains of blocks.'
230
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#single-line-blocks'
231
- Enabled: false
232
-
233
- Style/NegatedIf:
234
- Description: >-
235
- Favor unless over if for negative conditions
236
- (or control flow or).
237
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#unless-for-negatives'
238
- Enabled: false
239
-
240
- Style/NegatedWhile:
241
- Description: 'Favor until over while for negative conditions.'
242
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#until-for-negatives'
243
- Enabled: false
244
-
245
- Style/Next:
246
- Description: 'Use `next` to skip iteration instead of a condition at the end.'
247
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-nested-conditionals'
248
- Enabled: false
249
-
250
- Style/NilComparison:
251
- Description: 'Prefer x.nil? to x == nil.'
252
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#predicate-methods'
253
- Enabled: false
254
-
255
- Style/Not:
256
- Description: 'Use ! instead of not.'
257
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#bang-not-not'
258
- Enabled: false
259
-
260
- Style/NumericLiterals:
261
- Description: >-
262
- Add underscores to large numeric literals to improve their
263
- readability.
264
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#underscores-in-numerics'
265
- Enabled: false
266
-
267
- Style/OneLineConditional:
268
- Description: >-
269
- Favor the ternary operator(?:) over
270
- if/then/else/end constructs.
271
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#ternary-operator'
272
- Enabled: false
273
-
274
- Naming/BinaryOperatorParameterName:
275
- Description: 'When defining binary operators, name the argument other.'
276
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#other-arg'
277
- Enabled: false
278
-
279
- Metrics/ParameterLists:
280
- Description: 'Avoid parameter lists longer than three or four parameters.'
281
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#too-many-params'
282
- Enabled: false
283
-
284
- Style/PercentLiteralDelimiters:
285
- Description: 'Use `%`-literal delimiters consistently'
286
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#percent-literal-braces'
287
- Enabled: false
288
-
289
- Style/PerlBackrefs:
290
- Description: 'Avoid Perl-style regex back references.'
291
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-perl-regexp-last-matchers'
292
- Enabled: false
293
-
294
- Naming/PredicateName:
295
- Description: 'Check the names of predicate methods.'
296
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#bool-methods-qmark'
297
- NamePrefixBlacklist:
298
- - is_
299
- Exclude:
300
- - spec/**/*
301
-
302
- Style/Proc:
303
- Description: 'Use proc instead of Proc.new.'
304
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#proc'
305
- Enabled: false
306
-
307
- Style/RaiseArgs:
308
- Description: 'Checks the arguments passed to raise/fail.'
309
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#exception-class-messages'
310
- Enabled: false
311
-
312
- Style/RegexpLiteral:
313
- Description: 'Use / or %r around regular expressions.'
314
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#percent-r'
315
- Enabled: false
316
-
317
- Style/SelfAssignment:
318
- Description: >-
319
- Checks for places where self-assignment shorthand should have
320
- been used.
321
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#self-assignment'
322
- Enabled: false
1
+ # Auto-generated by Cimas: Do not edit it manually!
2
+ # See https://github.com/metanorma/cimas
3
+ inherit_from:
4
+ - https://raw.githubusercontent.com/riboseinc/oss-guides/master/ci/rubocop.yml
323
5
 
324
- Style/SingleLineBlockParams:
325
- Description: 'Enforces the names of some block params.'
326
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#reduce-blocks'
327
- Enabled: false
6
+ # local repo-specific modifications
7
+ # ...
328
8
 
329
- Style/SingleLineMethods:
330
- Description: 'Avoid single-line methods.'
331
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-single-line-methods'
332
- Enabled: false
333
-
334
- Style/SignalException:
335
- Description: 'Checks for proper usage of fail and raise.'
336
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#fail-method'
337
- Enabled: false
338
-
339
- Style/SpecialGlobalVars:
340
- Description: 'Avoid Perl-style global variables.'
341
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-cryptic-perlisms'
342
- Enabled: false
343
-
344
- Style/StringLiterals:
345
- Description: 'Checks if uses of quotes match the configured preference.'
346
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#consistent-string-literals'
347
- EnforcedStyle: double_quotes
348
- Enabled: true
349
-
350
- Style/TrailingCommaInArguments:
351
- Description: 'Checks for trailing comma in argument lists.'
352
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-trailing-array-commas'
353
- EnforcedStyleForMultiline: comma
354
- SupportedStylesForMultiline:
355
- - comma
356
- - consistent_comma
357
- - no_comma
358
- Enabled: true
359
-
360
- Style/TrailingCommaInLiteral:
361
- Description: 'Checks for trailing comma in array and hash literals.'
362
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-trailing-array-commas'
363
- EnforcedStyleForMultiline: comma
364
- SupportedStylesForMultiline:
365
- - comma
366
- - consistent_comma
367
- - no_comma
368
- Enabled: true
369
-
370
- Style/TrivialAccessors:
371
- Description: 'Prefer attr_* methods to trivial readers/writers.'
372
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#attr_family'
373
- Enabled: false
374
-
375
- Style/VariableInterpolation:
376
- Description: >-
377
- Don't interpolate global, instance and class variables
378
- directly in strings.
379
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#curlies-interpolate'
380
- Enabled: false
381
-
382
- Style/WhenThen:
383
- Description: 'Use when x then ... for one-line cases.'
384
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#one-line-cases'
385
- Enabled: false
386
-
387
- Style/WhileUntilModifier:
388
- Description: >-
389
- Favor modifier while/until usage when you have a
390
- single-line body.
391
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#while-as-a-modifier'
392
- Enabled: false
393
-
394
- Style/WordArray:
395
- Description: 'Use %w or %W for arrays of words.'
396
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#percent-w'
397
- Enabled: false
398
-
399
- # Layout
400
-
401
- Layout/AlignParameters:
402
- Description: 'Here we check if the parameters on a multi-line method call or definition are aligned.'
403
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-double-indent'
404
- Enabled: false
405
-
406
- Layout/DotPosition:
407
- Description: 'Checks the position of the dot in multi-line method calls.'
408
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#consistent-multi-line-chains'
409
- EnforcedStyle: trailing
410
-
411
- Layout/ExtraSpacing:
412
- Description: 'Do not use unnecessary spacing.'
413
- Enabled: true
414
-
415
- Layout/MultilineOperationIndentation:
416
- Description: >-
417
- Checks indentation of binary operations that span more than
418
- one line.
419
- Enabled: true
420
- EnforcedStyle: indented
421
-
422
- Layout/MultilineMethodCallIndentation:
423
- Description: >-
424
- Checks indentation of method calls with the dot operator
425
- that span more than one line.
426
- Enabled: true
427
- EnforcedStyle: indented
428
-
429
- Layout/InitialIndentation:
430
- Description: >-
431
- Checks the indentation of the first non-blank non-comment line in a file.
432
- Enabled: false
433
-
434
- # Lint
435
-
436
- Lint/AmbiguousOperator:
437
- Description: >-
438
- Checks for ambiguous operators in the first argument of a
439
- method invocation without parentheses.
440
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#parens-as-args'
441
- Enabled: false
442
-
443
- Lint/AmbiguousRegexpLiteral:
444
- Description: >-
445
- Checks for ambiguous regexp literals in the first argument of
446
- a method invocation without parenthesis.
447
- Enabled: false
448
-
449
- Lint/AssignmentInCondition:
450
- Description: "Don't use assignment in conditions."
451
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#safe-assignment-in-condition'
452
- Enabled: false
453
-
454
- Lint/CircularArgumentReference:
455
- Description: "Don't refer to the keyword argument in the default value."
456
- Enabled: false
457
-
458
- Lint/ConditionPosition:
459
- Description: >-
460
- Checks for condition placed in a confusing position relative to
461
- the keyword.
462
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#same-line-condition'
463
- Enabled: false
464
-
465
- Lint/DeprecatedClassMethods:
466
- Description: 'Check for deprecated class method calls.'
467
- Enabled: false
468
-
469
- Lint/DuplicatedKey:
470
- Description: 'Check for duplicate keys in hash literals.'
471
- Enabled: false
472
-
473
- Lint/EachWithObjectArgument:
474
- Description: 'Check for immutable argument given to each_with_object.'
475
- Enabled: false
476
-
477
- Lint/ElseLayout:
478
- Description: 'Check for odd code arrangement in an else block.'
479
- Enabled: false
480
-
481
- Lint/FormatParameterMismatch:
482
- Description: 'The number of parameters to format/sprint must match the fields.'
483
- Enabled: false
484
-
485
- Lint/HandleExceptions:
486
- Description: "Don't suppress exception."
487
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#dont-hide-exceptions'
488
- Enabled: false
489
-
490
- Lint/LiteralInCondition:
491
- Description: 'Checks of literals used in conditions.'
492
- Enabled: false
493
-
494
- Lint/LiteralInInterpolation:
495
- Description: 'Checks for literals used in interpolation.'
496
- Enabled: false
497
-
498
- Lint/Loop:
499
- Description: >-
500
- Use Kernel#loop with break rather than begin/end/until or
501
- begin/end/while for post-loop tests.
502
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#loop-with-break'
503
- Enabled: false
504
-
505
- Lint/NestedMethodDefinition:
506
- Description: 'Do not use nested method definitions.'
507
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-nested-methods'
508
- Enabled: false
509
-
510
- Lint/NonLocalExitFromIterator:
511
- Description: 'Do not use return in iterator to cause non-local exit.'
512
- Enabled: false
513
-
514
- Lint/ParenthesesAsGroupedExpression:
515
- Description: >-
516
- Checks for method calls with a space before the opening
517
- parenthesis.
518
- StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#parens-no-spaces'
519
- Enabled: false
520
-
521
- Lint/RequireParentheses:
522
- Description: >-
523
- Use parentheses in the method call to avoid confusion
524
- about precedence.
525
- Enabled: false
526
-
527
- Lint/UnderscorePrefixedVariableName:
528
- Description: 'Do not use prefix `_` for a variable that is used.'
529
- Enabled: false
530
-
531
- Lint/UnneededDisable:
532
- Description: >-
533
- Checks for rubocop:disable comments that can be removed.
534
- Note: this cop is not disabled when disabling all cops.
535
- It must be explicitly disabled.
536
- Enabled: false
537
-
538
- Lint/Void:
539
- Description: 'Possible use of operator/literal/variable in void context.'
540
- Enabled: false
541
-
542
- # Performance
543
-
544
- Performance/CaseWhenSplat:
545
- Description: >-
546
- Place `when` conditions that use splat at the end
547
- of the list of `when` branches.
548
- Enabled: false
549
-
550
- Performance/Count:
551
- Description: >-
552
- Use `count` instead of `select...size`, `reject...size`,
553
- `select...count`, `reject...count`, `select...length`,
554
- and `reject...length`.
555
- Enabled: false
556
-
557
- Performance/Detect:
558
- Description: >-
559
- Use `detect` instead of `select.first`, `find_all.first`,
560
- `select.last`, and `find_all.last`.
561
- Reference: 'https://github.com/JuanitoFatas/fast-ruby#enumerabledetect-vs-enumerableselectfirst-code'
562
- Enabled: false
563
-
564
- Performance/FlatMap:
565
- Description: >-
566
- Use `Enumerable#flat_map`
567
- instead of `Enumerable#map...Array#flatten(1)`
568
- or `Enumberable#collect..Array#flatten(1)`
569
- Reference: 'https://github.com/JuanitoFatas/fast-ruby#enumerablemaparrayflatten-vs-enumerableflat_map-code'
570
- Enabled: false
571
-
572
- Performance/ReverseEach:
573
- Description: 'Use `reverse_each` instead of `reverse.each`.'
574
- Reference: 'https://github.com/JuanitoFatas/fast-ruby#enumerablereverseeach-vs-enumerablereverse_each-code'
575
- Enabled: false
576
-
577
- Performance/Sample:
578
- Description: >-
579
- Use `sample` instead of `shuffle.first`,
580
- `shuffle.last`, and `shuffle[Fixnum]`.
581
- Reference: 'https://github.com/JuanitoFatas/fast-ruby#arrayshufflefirst-vs-arraysample-code'
582
- Enabled: false
583
-
584
- Performance/Size:
585
- Description: >-
586
- Use `size` instead of `count` for counting
587
- the number of elements in `Array` and `Hash`.
588
- Reference: 'https://github.com/JuanitoFatas/fast-ruby#arraycount-vs-arraysize-code'
589
- Enabled: false
590
-
591
- Performance/StringReplacement:
592
- Description: >-
593
- Use `tr` instead of `gsub` when you are replacing the same
594
- number of characters. Use `delete` instead of `gsub` when
595
- you are deleting characters.
596
- Reference: 'https://github.com/JuanitoFatas/fast-ruby#stringgsub-vs-stringtr-code'
597
- Enabled: false
598
-
599
- # Rails
600
-
601
- Rails/ActionFilter:
602
- Description: 'Enforces consistent use of action filter methods.'
603
- Enabled: false
604
-
605
- Rails/Date:
606
- Description: >-
607
- Checks the correct usage of date aware methods,
608
- such as Date.today, Date.current etc.
609
- Enabled: false
610
-
611
- Rails/FindBy:
612
- Description: 'Prefer find_by over where.first.'
613
- Enabled: false
614
-
615
- Rails/FindEach:
616
- Description: 'Prefer all.find_each over all.find.'
617
- Enabled: false
618
-
619
- Rails/HasAndBelongsToMany:
620
- Description: 'Prefer has_many :through to has_and_belongs_to_many.'
621
- Enabled: false
622
-
623
- Rails/Output:
624
- Description: 'Checks for calls to puts, print, etc.'
625
- Enabled: false
626
-
627
- Rails/ReadWriteAttribute:
628
- Description: >-
629
- Checks for read_attribute(:attr) and
630
- write_attribute(:attr, val).
631
- Enabled: false
632
-
633
- Rails/ScopeArgs:
634
- Description: 'Checks the arguments of ActiveRecord scopes.'
635
- Enabled: false
636
-
637
- Rails/TimeZone:
638
- Description: 'Checks the correct usage of time zone aware methods.'
639
- StyleGuide: 'https://github.com/bbatsov/rails-style-guide#time'
640
- Reference: 'http://danilenko.org/2012/7/6/rails_timezones'
641
- Enabled: false
642
-
643
- Rails/Validation:
644
- Description: 'Use validates :attribute, hash of validations.'
645
- Enabled: false
9
+ AllCops:
10
+ TargetRubyVersion: 2.5