active_record_tweaks 0.2.0 → 0.2.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
  SHA1:
3
- metadata.gz: f5b2a9296038a6dc1f37c0d7dd5c7cf813ca8f00
4
- data.tar.gz: 8f1a93dad09bc2c0561ac57d68e9added379fdde
3
+ metadata.gz: 799161ccbdfdb68c45a649865c8c0caef0088060
4
+ data.tar.gz: 2b6edb80be5cfe087f8cc475798437716d0d7024
5
5
  SHA512:
6
- metadata.gz: 52745cf34fb2fd5b7cce8983cc6ac20e8c5c9a8e05c1234561da7598caf97eadf49f567e393c216d65546275c4c110bc708d009040c5ebccd8589bdcb90e63a3
7
- data.tar.gz: 0ca70c7afec28a89e85892cc59696daeef0666722dd04fb2812f7077adbb4fb847f6b4b386d6823d517b3edbeb7187971cd2860c2f9ec3cfbcd9efc1c204fa1e
6
+ metadata.gz: a43c5349f9fa2fd3bb03e4d660f946b135ab0266cb7eb1d2283f99b9843573992acfda530d1b896009a177197657b426a33b8db9c311361738c2b7a951272128
7
+ data.tar.gz: 77d5fe90a3cec07062d3fe63b71a18d92364eff08f3c371a66f03c256b44e5471f46bf9abec435b50494c9677b5de2f59b0c4cb2ecc1adf0b3ae6d40f467e166
data/.gitignore CHANGED
@@ -1,2 +1,8 @@
1
- gemfiles/*.gemfile.lock
2
1
  Gemfile.lock
2
+ # Ignore Coverage Report
3
+ coverage/.last_run.json
4
+ coverage/.resultset.json
5
+ # Ignore Appraisal related files
6
+ gemfiles/*.gemfile.lock
7
+ pkg/*
8
+ .idea/
@@ -0,0 +1,803 @@
1
+ # This is the default configuration file. Enabling and disabling is configured
2
+ # in separate files. This file adds all other parameters apart from Enabled.
3
+
4
+ # Common configuration.
5
+ AllCops:
6
+ # Include gemspec and Rakefile
7
+ Include:
8
+ - "**/*.gemspec"
9
+ - "**/*.podspec"
10
+ - "**/*.jbuilder"
11
+ - "**/*.rake"
12
+ - "**/*.opal"
13
+ - "**/Gemfile"
14
+ - "**/Rakefile"
15
+ - "**/Capfile"
16
+ - "**/Guardfile"
17
+ - "**/Podfile"
18
+ - "**/Thorfile"
19
+ - "**/Vagrantfile"
20
+ - "**/Berksfile"
21
+ - "**/Cheffile"
22
+ - "**/Vagabondfile"
23
+ Exclude:
24
+ - "vendor/**/*"
25
+ - "gemfiles/vendor/**/*"
26
+ # Cop names are not displayed in offense messages by default. Change behavior
27
+ # by overriding DisplayCopNames, or by giving the -D/--display-cop-names
28
+ # option.
29
+ DisplayCopNames: true
30
+ # Style guide URLs are not displayed in offense messages by default. Change
31
+ # behavior by overriding DisplayStyleGuide, or by giving the
32
+ # -S/--display-style-guide option.
33
+ DisplayStyleGuide: false
34
+ # Additional cops that do not reference a style guide rule may be enabled by
35
+ # default. Change behavior by overriding StyleGuideCopsOnly, or by giving
36
+ # the --only-guide-cops option.
37
+ StyleGuideCopsOnly: false
38
+
39
+ # Indent private/protected/public as deep as method definitions
40
+ Style/AccessModifierIndentation:
41
+ EnforcedStyle: indent
42
+ SupportedStyles:
43
+ - outdent
44
+ - indent
45
+
46
+ # Align the elements of a hash literal if they span more than one line.
47
+ Style/AlignHash:
48
+ # Alignment of entries using hash rocket as separator. Valid values are:
49
+ #
50
+ # key - left alignment of keys
51
+ # "a" => 2
52
+ # "bb" => 3
53
+ # separator - alignment of hash rockets, keys are right aligned
54
+ # "a" => 2
55
+ # "bb" => 3
56
+ # table - left alignment of keys, hash rockets, and values
57
+ # "a" => 2
58
+ # "bb" => 3
59
+ EnforcedHashRocketStyle: table
60
+ # Alignment of entries using colon as separator. Valid values are:
61
+ #
62
+ # key - left alignment of keys
63
+ # a: 0
64
+ # bb: 1
65
+ # separator - alignment of colons, keys are right aligned
66
+ # a: 0
67
+ # bb: 1
68
+ # table - left alignment of keys and values
69
+ # a: 0
70
+ # bb: 1
71
+ EnforcedColonStyle: table
72
+ # Select whether hashes that are the last argument in a method call should be
73
+ # inspected? Valid values are:
74
+ #
75
+ # always_inspect - Inspect both implicit and explicit hashes.
76
+ # Registers an offense for:
77
+ # function(a: 1,
78
+ # b: 2)
79
+ # Registers an offense for:
80
+ # function({a: 1,
81
+ # b: 2})
82
+ # always_ignore - Ignore both implicit and explicit hashes.
83
+ # Accepts:
84
+ # function(a: 1,
85
+ # b: 2)
86
+ # Accepts:
87
+ # function({a: 1,
88
+ # b: 2})
89
+ # ignore_implicit - Ignore only implicit hashes.
90
+ # Accepts:
91
+ # function(a: 1,
92
+ # b: 2)
93
+ # Registers an offense for:
94
+ # function({a: 1,
95
+ # b: 2})
96
+ # ignore_explicit - Ignore only explicit hashes.
97
+ # Accepts:
98
+ # function({a: 1,
99
+ # b: 2})
100
+ # Registers an offense for:
101
+ # function(a: 1,
102
+ # b: 2)
103
+ EnforcedLastArgumentHashStyle: always_inspect
104
+ SupportedLastArgumentHashStyles:
105
+ - always_inspect
106
+ - always_ignore
107
+ - ignore_implicit
108
+ - ignore_explicit
109
+
110
+ Style/AlignParameters:
111
+ # Alignment of parameters in multi-line method calls.
112
+ #
113
+ # The `with_first_parameter` style aligns the following lines along the same
114
+ # column as the first parameter.
115
+ #
116
+ # method_call(a,
117
+ # b)
118
+ #
119
+ # The `with_fixed_indentation` style aligns the following lines with one
120
+ # level of indentation relative to the start of the line with the method call.
121
+ #
122
+ # method_call(a,
123
+ # b)
124
+ EnforcedStyle: with_fixed_indentation
125
+ SupportedStyles:
126
+ - with_first_parameter
127
+ - with_fixed_indentation
128
+
129
+ Style/AndOr:
130
+ # Whether `and` and `or` are banned only in conditionals (conditionals)
131
+ # or completely (always).
132
+ EnforcedStyle: always
133
+ SupportedStyles:
134
+ - always
135
+ - conditionals
136
+
137
+
138
+ # Checks if usage of %() or %Q() matches configuration.
139
+ Style/BarePercentLiterals:
140
+ EnforcedStyle: percent_q
141
+ SupportedStyles:
142
+ - percent_q
143
+ - bare_percent
144
+
145
+ Style/BlockDelimiters:
146
+ EnforcedStyle: line_count_based
147
+ SupportedStyles:
148
+ # The `line_count_based` style enforces braces around single line blocks and
149
+ # do..end around multi-line blocks.
150
+ - line_count_based
151
+ # The `semantic` style enforces braces around functional blocks, where the
152
+ # primary purpose of the block is to return a value and do..end for
153
+ # procedural blocks, where the primary purpose of the block is its
154
+ # side-effects.
155
+ #
156
+ # This looks at the usage of a block"s method to determine its type (e.g. is
157
+ # the result of a `map` assigned to a variable or passed to another
158
+ # method) but exceptions are permitted in the `ProceduralMethods`,
159
+ # `FunctionalMethods` and `IgnoredMethods` sections below.
160
+ - semantic
161
+ ProceduralMethods:
162
+ # Methods that are known to be procedural in nature but look functional from
163
+ # their usage, e.g.
164
+ #
165
+ # time = Benchmark.realtime do
166
+ # foo.bar
167
+ # end
168
+ #
169
+ # Here, the return value of the block is discarded but the return value of
170
+ # `Benchmark.realtime` is used.
171
+ - benchmark
172
+ - bm
173
+ - bmbm
174
+ - create
175
+ - each_with_object
176
+ - measure
177
+ - new
178
+ - realtime
179
+ - tap
180
+ - with_object
181
+ FunctionalMethods:
182
+ # Methods that are known to be functional in nature but look procedural from
183
+ # their usage, e.g.
184
+ #
185
+ # let(:foo) { Foo.new }
186
+ #
187
+ # Here, the return value of `Foo.new` is used to define a `foo` helper but
188
+ # doesn"t appear to be used from the return value of `let`.
189
+ - let
190
+ - let!
191
+ - subject
192
+ - watch
193
+ IgnoredMethods:
194
+ # Methods that can be either procedural or functional and cannot be
195
+ # categorised from their usage alone, e.g.
196
+ #
197
+ # foo = lambda do |x|
198
+ # puts "Hello, #{x}"
199
+ # end
200
+ #
201
+ # foo = lambda do |x|
202
+ # x * 100
203
+ # end
204
+ #
205
+ # Here, it is impossible to tell from the return value of `lambda` whether
206
+ # the inner block"s return value is significant.
207
+ - lambda
208
+ - proc
209
+ - it
210
+
211
+ Style/BracesAroundHashParameters:
212
+ EnforcedStyle: context_dependent
213
+ SupportedStyles:
214
+ # The `braces` style enforces braces around all method parameters that are
215
+ # hashes.
216
+ - braces
217
+ # The `no_braces` style checks that the last parameter doesn"t have braces
218
+ # around it.
219
+ - no_braces
220
+ # The `context_dependent` style checks that the last parameter doesn"t have
221
+ # braces around it, but requires braces if the second to last parameter is
222
+ # also a hash literal.
223
+ - context_dependent
224
+
225
+ # Indentation of `when`.
226
+ Style/CaseIndentation:
227
+ IndentWhenRelativeTo: case
228
+ SupportedStyles:
229
+ - case
230
+ - end
231
+ IndentOneStep: false
232
+
233
+ Style/ClassAndModuleChildren:
234
+ # Checks the style of children definitions at classes and modules.
235
+ #
236
+ # Basically there are two different styles:
237
+ #
238
+ # `nested` - have each child on a separate line
239
+ # class Foo
240
+ # class Bar
241
+ # end
242
+ # end
243
+ #
244
+ # `compact` - combine definitions as much as possible
245
+ # class Foo::Bar
246
+ # end
247
+ #
248
+ # The compact style is only forced, for classes / modules with one child.
249
+ EnforcedStyle: nested
250
+ SupportedStyles:
251
+ - nested
252
+ - compact
253
+
254
+ Style/ClassCheck:
255
+ EnforcedStyle: is_a?
256
+ SupportedStyles:
257
+ - is_a?
258
+ - kind_of?
259
+
260
+ # Align with the style guide.
261
+ Style/CollectionMethods:
262
+ # Mapping from undesired method to desired_method
263
+ # e.g. to use `detect` over `find`:
264
+ #
265
+ # CollectionMethods:
266
+ # PreferredMethods:
267
+ # find: detect
268
+ PreferredMethods:
269
+ collect: "map"
270
+ collect!: "map!"
271
+ inject: "reduce"
272
+ detect: "find"
273
+ find_all: "select"
274
+
275
+ # Use ` or %x around command literals.
276
+ Style/CommandLiteral:
277
+ EnforcedStyle: mixed
278
+ # backticks: Always use backticks.
279
+ # percent_x: Always use %x.
280
+ # mixed: Use backticks on single-line commands, and %x on multi-line commands.
281
+ SupportedStyles:
282
+ - backticks
283
+ - percent_x
284
+ - mixed
285
+ # If false, the cop will always recommend using %x if one or more backticks
286
+ # are found in the command string.
287
+ AllowInnerBackticks: false
288
+
289
+ # Checks formatting of special comments
290
+ Style/CommentAnnotation:
291
+ Keywords:
292
+ - TODO
293
+ - FIXME
294
+ - OPTIMIZE
295
+ - HACK
296
+ - REVIEW
297
+
298
+ # Checks that you have put a copyright in a comment before any code.
299
+ #
300
+ # You can override the default Notice in your .rubocop.yml file.
301
+ #
302
+ # In order to use autocorrect, you must supply a value for the
303
+ # AutocorrectNotice key that matches the regexp Notice. A blank
304
+ # AutocorrectNotice will cause an error during autocorrect.
305
+ #
306
+ # Autocorrect will add a copyright notice in a comment at the top
307
+ # of the file immediately after any shebang or encoding comments.
308
+ #
309
+ # Example rubocop.yml:
310
+ #
311
+ # Style/Copyright:
312
+ # Enabled: true
313
+ # Notice: "Copyright (\(c\) )?2015 Yahoo! Inc"
314
+ # AutocorrectNotice: "# Copyright (c) 2015 Yahoo! Inc."
315
+ #
316
+ Style/Copyright:
317
+ Enabled: false
318
+ Notice: '^Copyright (\(c\) )?2[0-9]{3} .+'
319
+ AutocorrectNotice: ""
320
+
321
+ Style/Documentation:
322
+ Enabled: false
323
+
324
+ # Multi-line method chaining should be done with leading dots.
325
+ Style/DotPosition:
326
+ EnforcedStyle: trailing
327
+ SupportedStyles:
328
+ - leading
329
+ - trailing
330
+
331
+ # Warn on empty else statements
332
+ # empty - warn only on empty else
333
+ # nil - warn on else with nil in it
334
+ # both - warn on empty else and else with nil in it
335
+ Style/EmptyElse:
336
+ EnforcedStyle: both
337
+ SupportedStyles:
338
+ - empty
339
+ - nil
340
+ - both
341
+
342
+ # Use empty lines between defs.
343
+ Style/EmptyLineBetweenDefs:
344
+ # If true, this parameter means that single line method definitions don"t
345
+ # need an empty line between them.
346
+ AllowAdjacentOneLineDefs: false
347
+
348
+ Style/EmptyLinesAroundBlockBody:
349
+ EnforcedStyle: no_empty_lines
350
+ SupportedStyles:
351
+ - empty_lines
352
+ - no_empty_lines
353
+
354
+ Style/EmptyLinesAroundClassBody:
355
+ EnforcedStyle: no_empty_lines
356
+ SupportedStyles:
357
+ - empty_lines
358
+ - no_empty_lines
359
+
360
+ Style/EmptyLinesAroundModuleBody:
361
+ EnforcedStyle: no_empty_lines
362
+ SupportedStyles:
363
+ - empty_lines
364
+ - no_empty_lines
365
+
366
+ # Checks whether the source file has a utf-8 encoding comment or not
367
+ # AutoCorrectEncodingComment must match the regex
368
+ # /#.*coding\s?[:=]\s?(?:UTF|utf)-8/
369
+ Style/Encoding:
370
+ EnforcedStyle: always
371
+ SupportedStyles:
372
+ - when_needed
373
+ - always
374
+ AutoCorrectEncodingComment: "# encoding: utf-8"
375
+
376
+ Style/FileName:
377
+ # File names listed in AllCops:Include are excluded by default. Add extra
378
+ # excludes here.
379
+ Exclude: []
380
+
381
+ Style/FirstParameterIndentation:
382
+ EnforcedStyle: special_for_inner_method_call_in_parentheses
383
+ SupportedStyles:
384
+ # The first parameter should always be indented one step more than the
385
+ # preceding line.
386
+ - consistent
387
+ # The first parameter should normally be indented one step more than the
388
+ # preceding line, but if it"s a parameter for a method call that is itself
389
+ # a parameter in a method call, then the inner parameter should be indented
390
+ # relative to the inner method.
391
+ - special_for_inner_method_call
392
+ # Same as special_for_inner_method_call except that the special rule only
393
+ # applies if the outer method call encloses its arguments in parentheses.
394
+ - special_for_inner_method_call_in_parentheses
395
+
396
+ # Checks use of for or each in multiline loops.
397
+ Style/For:
398
+ EnforcedStyle: each
399
+ SupportedStyles:
400
+ - for
401
+ - each
402
+
403
+ # Enforce the method used for string formatting.
404
+ Style/FormatString:
405
+ EnforcedStyle: format
406
+ SupportedStyles:
407
+ - format
408
+ - sprintf
409
+ - percent
410
+
411
+ # Built-in global variables are allowed by default.
412
+ Style/GlobalVars:
413
+ AllowedVariables: []
414
+
415
+ # `MinBodyLength` defines the number of lines of the a body of an if / unless
416
+ # needs to have to trigger this cop
417
+ Style/GuardClause:
418
+ MinBodyLength: 1
419
+
420
+ Style/HashSyntax:
421
+ EnforcedStyle: ruby19_no_mixed_keys
422
+ SupportedStyles:
423
+ - ruby19
424
+ - ruby19_no_mixed_keys
425
+ - hash_rockets
426
+ # Force hashes that have a symbol value to use hash rockets
427
+ UseHashRocketsWithSymbolValues: false
428
+
429
+ Style/IfUnlessModifier:
430
+ MaxLineLength: 80
431
+
432
+ Style/IndentationConsistency:
433
+ # The difference between `rails` and `normal` is that the `rails` style
434
+ # prescribes that in classes and modules the `protected` and `private`
435
+ # modifier keywords shall be indented the same as public methods and that
436
+ # protected and private members shall be indented one step more than the
437
+ # modifiers. Other than that, both styles mean that entities on the same
438
+ # logical depth shall have the same indentation.
439
+ EnforcedStyle: normal
440
+ SupportedStyles:
441
+ - normal
442
+ - rails
443
+
444
+ Style/IndentationWidth:
445
+ # Number of spaces for each indentation level.
446
+ Width: 2
447
+
448
+ # Checks the indentation of the first key in a hash literal.
449
+ Style/IndentHash:
450
+ # The value `special_inside_parentheses` means that hash literals with braces
451
+ # that have their opening brace on the same line as a surrounding opening
452
+ # round parenthesis, shall have their first key indented relative to the
453
+ # first position inside the parenthesis.
454
+ # The value `consistent` means that the indentation of the first key shall
455
+ # always be relative to the first position of the line where the opening
456
+ # brace is.
457
+ EnforcedStyle: special_inside_parentheses
458
+ SupportedStyles:
459
+ - special_inside_parentheses
460
+ - consistent
461
+
462
+ Style/LambdaCall:
463
+ EnforcedStyle: call
464
+ SupportedStyles:
465
+ - call
466
+ - braces
467
+
468
+ Style/Next:
469
+ # With `always` all conditions at the end of an iteration needs to be
470
+ # replaced by next - with `skip_modifier_ifs` the modifier if like this one
471
+ # are ignored: [1, 2].each { |a| return "yes" if a == 1 }
472
+ EnforcedStyle: skip_modifier_ifs
473
+ # `MinBodyLength` defines the number of lines of the a body of an if / unless
474
+ # needs to have to trigger this cop
475
+ MinBodyLength: 3
476
+ SupportedStyles:
477
+ - skip_modifier_ifs
478
+ - always
479
+
480
+ Style/NonNilCheck:
481
+ # With `IncludeSemanticChanges` set to `true`, this cop reports offenses for
482
+ # `!x.nil?` and autocorrects that and `x != nil` to solely `x`, which is
483
+ # **usually** OK, but might change behavior.
484
+ #
485
+ # With `IncludeSemanticChanges` set to `false`, this cop does not report
486
+ # offenses for `!x.nil?` and does no changes that might change behavior.
487
+ IncludeSemanticChanges: false
488
+
489
+ Style/MethodDefParentheses:
490
+ EnforcedStyle: require_parentheses
491
+ SupportedStyles:
492
+ - require_parentheses
493
+ - require_no_parentheses
494
+
495
+ Style/MethodName:
496
+ EnforcedStyle: snake_case
497
+ SupportedStyles:
498
+ - snake_case
499
+ - camelCase
500
+
501
+ Style/MultilineOperationIndentation:
502
+ EnforcedStyle: aligned
503
+ SupportedStyles:
504
+ - aligned
505
+ - indented
506
+
507
+ Style/NumericLiterals:
508
+ MinDigits: 5
509
+
510
+ # Allow safe assignment in conditions.
511
+ Style/ParenthesesAroundCondition:
512
+ AllowSafeAssignment: true
513
+
514
+ Style/PercentLiteralDelimiters:
515
+ PreferredDelimiters:
516
+ "%": ()
517
+ "%i": ()
518
+ "%q": ()
519
+ "%Q": ()
520
+ "%r": "||"
521
+ "%s": ()
522
+ "%w": ()
523
+ "%W": ()
524
+ "%x": ()
525
+
526
+ Style/PercentQLiterals:
527
+ EnforcedStyle: upper_case_q
528
+ SupportedStyles:
529
+ - lower_case_q # Use %q when possible, %Q when necessary
530
+ - upper_case_q # Always use %Q
531
+
532
+ Style/PredicateName:
533
+ # Predicate name prefices.
534
+ NamePrefix:
535
+ - is_
536
+ - has_
537
+ - have_
538
+ # Predicate name prefices that should be removed.
539
+ NamePrefixBlacklist:
540
+ - is_
541
+ - has_
542
+ - have_
543
+
544
+ Style/RaiseArgs:
545
+ EnforcedStyle: exploded
546
+ SupportedStyles:
547
+ - compact # raise Exception.new(msg)
548
+ - exploded # raise Exception, msg
549
+
550
+ Style/RedundantReturn:
551
+ # When true allows code like `return x, y`.
552
+ AllowMultipleReturnValues: false
553
+
554
+ # Use / or %r around regular expressions.
555
+ Style/RegexpLiteral:
556
+ EnforcedStyle: mixed
557
+ # slashes: Always use slashes.
558
+ # percent_r: Always use %r.
559
+ # mixed: Use slashes on single-line regexes, and %r on multi-line regexes.
560
+ SupportedStyles:
561
+ - slashes
562
+ - percent_r
563
+ - mixed
564
+ # If false, the cop will always recommend using %r if one or more slashes
565
+ # are found in the regexp string.
566
+ AllowInnerSlashes: false
567
+
568
+ Style/Semicolon:
569
+ # Allow ; to separate several expressions on the same line.
570
+ AllowAsExpressionSeparator: false
571
+
572
+ Style/SignalException:
573
+ EnforcedStyle: only_fail
574
+ SupportedStyles:
575
+ - only_raise
576
+ - only_fail
577
+ - semantic
578
+
579
+ Style/SingleLineBlockParams:
580
+ Methods:
581
+ - reduce:
582
+ - a
583
+ - e
584
+ - inject:
585
+ - a
586
+ - e
587
+
588
+ Style/SingleLineMethods:
589
+ AllowIfMethodIsEmpty: true
590
+
591
+ Style/StringLiterals:
592
+ EnforcedStyle: double_quotes
593
+ SupportedStyles:
594
+ - single_quotes
595
+ - double_quotes
596
+
597
+ Style/StringLiteralsInInterpolation:
598
+ EnforcedStyle: double_quotes
599
+ SupportedStyles:
600
+ - single_quotes
601
+ - double_quotes
602
+
603
+ Style/SpaceAroundBlockParameters:
604
+ EnforcedStyleInsidePipes: no_space
605
+ SupportedStyles:
606
+ - space
607
+ - no_space
608
+
609
+ Style/SpaceAroundEqualsInParameterDefault:
610
+ EnforcedStyle: space
611
+ SupportedStyles:
612
+ - space
613
+ - no_space
614
+
615
+ Style/SpaceAroundOperators:
616
+ AllowForAlignment: true
617
+
618
+ Style/SpaceBeforeBlockBraces:
619
+ EnforcedStyle: space
620
+ SupportedStyles:
621
+ - space
622
+ - no_space
623
+
624
+ Style/SpaceInsideBlockBraces:
625
+ EnforcedStyle: space
626
+ SupportedStyles:
627
+ - space
628
+ - no_space
629
+ # Valid values are: space, no_space
630
+ EnforcedStyleForEmptyBraces: no_space
631
+ # Space between { and |. Overrides EnforcedStyle if there is a conflict.
632
+ SpaceBeforeBlockParameters: true
633
+
634
+ Style/SpaceInsideHashLiteralBraces:
635
+ EnforcedStyle: no_space
636
+ EnforcedStyleForEmptyBraces: no_space
637
+ SupportedStyles:
638
+ - space
639
+ - no_space
640
+
641
+ Style/SymbolProc:
642
+ # A list of method names to be ignored by the check.
643
+ # The names should be fairly unique, otherwise you"ll end up ignoring lots of code.
644
+ IgnoredMethods:
645
+ - respond_to
646
+
647
+ Style/TrailingBlankLines:
648
+ EnforcedStyle: final_newline
649
+ SupportedStyles:
650
+ - final_newline
651
+ - final_blank_line
652
+
653
+ Style/TrailingCommaInArguments:
654
+ # If `comma`, the cop requires a comma after the last argument, but only for
655
+ # parenthesized method calls where each argument is on its own line.
656
+ # If `consistent_comma`, the cop requires a comma after the last argument,
657
+ # for all parenthesized method calls with arguments.
658
+ EnforcedStyleForMultiline: comma
659
+ SupportedStyles:
660
+ - comma
661
+ - consistent_comma
662
+ - no_comma
663
+
664
+ Style/TrailingCommaInLiteral:
665
+ # If `comma`, the cop requires a comma after the last item in an array or
666
+ # hash, but only when each item is on its own line.
667
+ # If `consistent_comma`, the cop requires a comma after the last item of all
668
+ # non-empty array and hash literals.
669
+ EnforcedStyleForMultiline: comma
670
+ SupportedStyles:
671
+ - comma
672
+ - consistent_comma
673
+ - no_comma
674
+
675
+ # TrivialAccessors requires exact name matches and doesn"t allow
676
+ # predicated methods by default.
677
+ Style/TrivialAccessors:
678
+ # When set to false the cop will suggest the use of accessor methods
679
+ # in situations like:
680
+ #
681
+ # def name
682
+ # @other_name
683
+ # end
684
+ #
685
+ # This way you can uncover "hidden" attributes in your code.
686
+ ExactNameMatch: false
687
+ AllowPredicates: false
688
+ # Allows trivial writers that don"t end in an equal sign. e.g.
689
+ #
690
+ # def on_exception(action)
691
+ # @on_exception=action
692
+ # end
693
+ # on_exception :restart
694
+ #
695
+ # Commonly used in DSLs
696
+ AllowDSLWriters: false
697
+ IgnoreClassMethods: false
698
+ Whitelist:
699
+ - to_ary
700
+ - to_a
701
+ - to_c
702
+ - to_enum
703
+ - to_h
704
+ - to_hash
705
+ - to_i
706
+ - to_int
707
+ - to_io
708
+ - to_open
709
+ - to_path
710
+ - to_proc
711
+ - to_r
712
+ - to_regexp
713
+ - to_str
714
+ - to_s
715
+ - to_sym
716
+
717
+ Style/UnneededPercentQ:
718
+ Enabled: false
719
+
720
+ Style/VariableName:
721
+ EnforcedStyle: snake_case
722
+ SupportedStyles:
723
+ - snake_case
724
+ - camelCase
725
+
726
+ Style/WhileUntilModifier:
727
+ MaxLineLength: 80
728
+
729
+ Style/WordArray:
730
+ MinSize: 0
731
+ # The regular expression WordRegex decides what is considered a word.
732
+ WordRegex: !ruby/regexp '/\A[\p{Word}]+\z/'
733
+
734
+ ##################### Metrics ##################################
735
+
736
+ Metrics/AbcSize:
737
+ # The ABC size is a calculated magnitude, so this number can be a Fixnum or
738
+ # a Float.
739
+ Max: 15
740
+
741
+ Metrics/BlockNesting:
742
+ Max: 3
743
+
744
+ Metrics/ClassLength:
745
+ CountComments: false # count full line comments?
746
+ Max: 100
747
+
748
+ # Avoid complex methods.
749
+ Metrics/CyclomaticComplexity:
750
+ Max: 6
751
+
752
+ Metrics/LineLength:
753
+ Max: 100
754
+ # To make it possible to copy or click on URIs in the code, we allow lines
755
+ # contaning a URI to be longer than Max.
756
+ AllowURI: true
757
+ URISchemes:
758
+ - http
759
+ - https
760
+
761
+ Metrics/MethodLength:
762
+ CountComments: false # count full line comments?
763
+ Max: 10
764
+
765
+ Metrics/ParameterLists:
766
+ Max: 5
767
+ CountKeywordArgs: true
768
+
769
+ Metrics/PerceivedComplexity:
770
+ Max: 7
771
+
772
+ ##################### Lint ##################################
773
+
774
+ # Allow safe assignment in conditions.
775
+ Lint/AssignmentInCondition:
776
+ AllowSafeAssignment: true
777
+
778
+ # Align ends correctly.
779
+ Lint/EndAlignment:
780
+ # The value `keyword` means that `end` should be aligned with the matching
781
+ # keyword (if, while, etc.).
782
+ # The value `variable` means that in assignments, `end` should be aligned
783
+ # with the start of the variable on the left hand side of `=`. In all other
784
+ # situations, `end` should still be aligned with the keyword.
785
+ AlignWith: variable
786
+ SupportedStyles:
787
+ - keyword
788
+ - variable
789
+
790
+ Lint/DefEndAlignment:
791
+ # The value `def` means that `end` should be aligned with the def keyword.
792
+ # The value `start_of_line` means that `end` should be aligned with method
793
+ # calls like `private`, `public`, etc, if present in front of the `def`
794
+ # keyword on the same line.
795
+ AlignWith: start_of_line
796
+ SupportedStyles:
797
+ - start_of_line
798
+ - def
799
+
800
+ ##################### Rails ##################################
801
+
802
+ Rails:
803
+ Enabled: false