execute_with_rescue_with_airbrake 0.0.2 → 0.0.3

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