linkedin_v2 1.0.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.
Files changed (42) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +11 -0
  3. data/.reek.yml +12 -0
  4. data/.rspec +3 -0
  5. data/.rubocop.yml +1175 -0
  6. data/.ruby-version +1 -0
  7. data/.travis.yml +7 -0
  8. data/Gemfile +4 -0
  9. data/Gemfile.lock +135 -0
  10. data/LICENSE.txt +21 -0
  11. data/README.md +38 -0
  12. data/Rakefile +6 -0
  13. data/bin/console +14 -0
  14. data/bin/setup +8 -0
  15. data/lib/linkedin_v2/api/medias.rb +15 -0
  16. data/lib/linkedin_v2/api/organizations.rb +41 -0
  17. data/lib/linkedin_v2/api/profiles.rb +32 -0
  18. data/lib/linkedin_v2/client.rb +18 -0
  19. data/lib/linkedin_v2/error.rb +16 -0
  20. data/lib/linkedin_v2/files/creator.rb +12 -0
  21. data/lib/linkedin_v2/files/destroyer.rb +12 -0
  22. data/lib/linkedin_v2/files/reader.rb +11 -0
  23. data/lib/linkedin_v2/helpers/attribute.rb +11 -0
  24. data/lib/linkedin_v2/helpers/handler.rb +25 -0
  25. data/lib/linkedin_v2/helpers/hash.rb +25 -0
  26. data/lib/linkedin_v2/helpers/url.rb +15 -0
  27. data/lib/linkedin_v2/templates/endpoints/company.erb +1 -0
  28. data/lib/linkedin_v2/templates/endpoints/logo.erb +1 -0
  29. data/lib/linkedin_v2/templates/endpoints/me.erb +1 -0
  30. data/lib/linkedin_v2/templates/endpoints/organizations.erb +1 -0
  31. data/lib/linkedin_v2/templates/endpoints/shares.erb +1 -0
  32. data/lib/linkedin_v2/templates/endpoints/ugc_post.erb +1 -0
  33. data/lib/linkedin_v2/templates/endpoints/upload_image.erb +1 -0
  34. data/lib/linkedin_v2/templates/payloads/base.rb +19 -0
  35. data/lib/linkedin_v2/templates/payloads/shares.rb +99 -0
  36. data/lib/linkedin_v2/templates/payloads/ugc_post.rb +76 -0
  37. data/lib/linkedin_v2/url/builder.rb +56 -0
  38. data/lib/linkedin_v2/url/response.rb +17 -0
  39. data/lib/linkedin_v2/version.rb +3 -0
  40. data/lib/linkedin_v2.rb +28 -0
  41. data/linkedin_v2.gemspec +48 -0
  42. metadata +250 -0
data/.rubocop.yml ADDED
@@ -0,0 +1,1175 @@
1
+ require: rubocop-performance
2
+ AllCops:
3
+ Exclude:
4
+ - 'db/migrate/*'
5
+ - 'tmp/**/*'
6
+ - 'node_modules/**/*'
7
+
8
+ DisabledByDefault: true
9
+ TargetRubyVersion: 2.6.2
10
+
11
+ #################### Layout ################################
12
+
13
+ Layout/AccessModifierIndentation:
14
+ Description: Check indentation of private/protected visibility modifiers.
15
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#indent-public-private-protected'
16
+ Enabled: false
17
+
18
+ Layout/AlignArray:
19
+ Description: >-
20
+ Align the elements of an array literal if they span more than
21
+ one line.
22
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#align-multiline-arrays'
23
+ Enabled: false
24
+
25
+ Layout/AlignHash:
26
+ Description: >-
27
+ Align the elements of a hash literal if they span more than
28
+ one line.
29
+ Enabled: false
30
+
31
+ Layout/AlignParameters:
32
+ Description: >-
33
+ Align the parameters of a method call if they span more
34
+ than one line.
35
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-double-indent'
36
+ Enabled: false
37
+
38
+ Layout/BlockEndNewline:
39
+ Description: 'Put end statement of multiline block on its own line.'
40
+ Enabled: false
41
+
42
+ Layout/CaseIndentation:
43
+ Description: 'Indentation of when in a case/when/[else/]end.'
44
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#indent-when-to-case'
45
+ Enabled: false
46
+
47
+ Layout/ClosingParenthesisIndentation:
48
+ Description: 'Checks the indentation of hanging closing parentheses.'
49
+ Enabled: false
50
+
51
+ Layout/CommentIndentation:
52
+ Description: 'Indentation of comments.'
53
+ Enabled: false
54
+
55
+ Layout/DotPosition:
56
+ Description: 'Checks the position of the dot in multi-line method calls.'
57
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#consistent-multi-line-chains'
58
+ Enabled: false
59
+
60
+ Layout/ElseAlignment:
61
+ Description: 'Align elses and elsifs correctly.'
62
+ Enabled: false
63
+
64
+ Layout/EmptyLineBetweenDefs:
65
+ Description: 'Use empty lines between defs.'
66
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#empty-lines-between-methods'
67
+ Enabled: false
68
+
69
+ Layout/EmptyLines:
70
+ Description: "Don't use several empty lines in a row."
71
+ Enabled: false
72
+
73
+ Layout/EmptyLinesAroundAccessModifier:
74
+ Description: "Keep blank lines around access modifiers."
75
+ Enabled: false
76
+
77
+ Layout/EmptyLinesAroundBlockBody:
78
+ Description: "Keeps track of empty lines around block bodies."
79
+ Enabled: false
80
+
81
+ Layout/EmptyLinesAroundClassBody:
82
+ Description: "Keeps track of empty lines around class bodies."
83
+ Enabled: false
84
+
85
+ Layout/EmptyLinesAroundModuleBody:
86
+ Description: "Keeps track of empty lines around module bodies."
87
+ Enabled: false
88
+
89
+ Layout/EmptyLinesAroundMethodBody:
90
+ Description: "Keeps track of empty lines around method bodies."
91
+ Enabled: false
92
+
93
+ Layout/EndOfLine:
94
+ Description: 'Use Unix-style line endings.'
95
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#crlf'
96
+ Enabled: false
97
+
98
+ Layout/ExtraSpacing:
99
+ Description: 'Do not use unnecessary spacing.'
100
+ Enabled: false
101
+
102
+ Layout/InitialIndentation:
103
+ Description: >-
104
+ Checks the indentation of the first non-blank non-comment line in a file.
105
+ Enabled: false
106
+
107
+ Layout/IndentFirstArgument:
108
+ Description: 'Checks the indentation of the first parameter in a method call.'
109
+ Enabled: false
110
+
111
+ Layout/IndentationConsistency:
112
+ Description: 'Keep indentation straight.'
113
+ Enabled: false
114
+
115
+ Layout/IndentationWidth:
116
+ Description: 'Use 2 spaces for indentation.'
117
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#spaces-indentation'
118
+ Enabled: false
119
+
120
+ Layout/IndentFirstArrayElement:
121
+ Description: >-
122
+ Checks the indentation of the first element in an array
123
+ literal.
124
+ Enabled: false
125
+
126
+ Layout/IndentFirstHashElement:
127
+ Description: 'Checks the indentation of the first key in a hash literal.'
128
+ Enabled: false
129
+
130
+ Layout/LeadingCommentSpace:
131
+ Description: 'Comments should start with a space.'
132
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#hash-space'
133
+ Enabled: false
134
+
135
+ Layout/MultilineBlockLayout:
136
+ Description: 'Ensures newlines after multiline block do statements.'
137
+ Enabled: false
138
+
139
+ Layout/MultilineOperationIndentation:
140
+ Description: >-
141
+ Checks indentation of binary operations that span more than
142
+ one line.
143
+ Enabled: false
144
+
145
+ Layout/RescueEnsureAlignment:
146
+ Description: 'Align rescues and ensures correctly.'
147
+ Enabled: false
148
+
149
+ Layout/SpaceBeforeFirstArg:
150
+ Description: >-
151
+ Checks that exactly one space is used between a method name
152
+ and the first argument for method calls without parentheses.
153
+ Enabled: true
154
+
155
+ Layout/SpaceAfterColon:
156
+ Description: 'Use spaces after colons.'
157
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#spaces-operators'
158
+ Enabled: false
159
+
160
+ Layout/SpaceAfterComma:
161
+ Description: 'Use spaces after commas.'
162
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#spaces-operators'
163
+ Enabled: false
164
+
165
+ Layout/SpaceAroundKeyword:
166
+ Description: 'Use spaces around keywords.'
167
+ Enabled: false
168
+
169
+ Layout/SpaceAfterMethodName:
170
+ Description: >-
171
+ Do not put a space between a method name and the opening
172
+ parenthesis in a method definition.
173
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#parens-no-spaces'
174
+ Enabled: false
175
+
176
+ Layout/SpaceAfterNot:
177
+ Description: Tracks redundant space after the ! operator.
178
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-space-bang'
179
+ Enabled: false
180
+
181
+ Layout/SpaceAfterSemicolon:
182
+ Description: 'Use spaces after semicolons.'
183
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#spaces-operators'
184
+ Enabled: false
185
+
186
+ Layout/SpaceBeforeBlockBraces:
187
+ Description: >-
188
+ Checks that the left block brace has or doesn't have space
189
+ before it.
190
+ Enabled: false
191
+
192
+ Layout/SpaceBeforeComma:
193
+ Description: 'No spaces before commas.'
194
+ Enabled: false
195
+
196
+ Layout/SpaceBeforeComment:
197
+ Description: >-
198
+ Checks for missing space between code and a comment on the
199
+ same line.
200
+ Enabled: false
201
+
202
+ Layout/SpaceBeforeSemicolon:
203
+ Description: 'No spaces before semicolons.'
204
+ Enabled: false
205
+
206
+ Layout/SpaceInsideBlockBraces:
207
+ Description: >-
208
+ Checks that block braces have or don't have surrounding space.
209
+ For blocks taking parameters, checks that the left brace has
210
+ or doesn't have trailing space.
211
+ Enabled: false
212
+
213
+ Layout/SpaceAroundBlockParameters:
214
+ Description: 'Checks the spacing inside and after block parameters pipes.'
215
+ Enabled: false
216
+
217
+ Layout/SpaceAroundEqualsInParameterDefault:
218
+ Description: >-
219
+ Checks that the equals signs in parameter default assignments
220
+ have or don't have surrounding space depending on
221
+ configuration.
222
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#spaces-around-equals'
223
+ Enabled: false
224
+
225
+ Layout/SpaceAroundOperators:
226
+ Description: 'Use a single space around operators.'
227
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#spaces-operators'
228
+ Enabled: false
229
+
230
+ Layout/SpaceInsideReferenceBrackets:
231
+ Description: 'No spaces after [ or before ].'
232
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-spaces-braces'
233
+ Enabled: true
234
+
235
+ Layout/SpaceInsideArrayLiteralBrackets:
236
+ Description: "Use spaces inside array literal braces - or don't."
237
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-spaces-braces'
238
+ Enabled: true
239
+ EnforcedStyle: space
240
+ EnforcedStyleForEmptyBrackets: no_space
241
+
242
+ Layout/SpaceInsideHashLiteralBraces:
243
+ Description: "Use spaces inside hash literal braces - or don't."
244
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#spaces-braces'
245
+ Enabled: true
246
+ EnforcedStyle: space
247
+ EnforcedStyleForEmptyBraces: no_space
248
+
249
+ Layout/SpaceInsideParens:
250
+ Description: 'No spaces after ( or before ).'
251
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-spaces-braces'
252
+ Enabled: false
253
+
254
+ Layout/SpaceInsideRangeLiteral:
255
+ Description: 'No spaces inside range literals.'
256
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-space-inside-range-literals'
257
+ Enabled: false
258
+
259
+ Layout/SpaceInsideStringInterpolation:
260
+ Description: 'Checks for padding/surrounding spaces inside string interpolation.'
261
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#string-interpolation'
262
+ Enabled: false
263
+
264
+ Layout/Tab:
265
+ Description: 'No hard tabs.'
266
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#spaces-indentation'
267
+ Enabled: false
268
+
269
+ Layout/TrailingBlankLines:
270
+ Description: 'Checks trailing blank lines and final newline.'
271
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#newline-eof'
272
+ Enabled: false
273
+
274
+ Layout/TrailingWhitespace:
275
+ Description: 'Avoid trailing whitespace.'
276
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-trailing-whitespace'
277
+ Enabled: false
278
+
279
+ #################### Lint ################################
280
+
281
+ Lint/AmbiguousOperator:
282
+ Description: >-
283
+ Checks for ambiguous operators in the first argument of a
284
+ method invocation without parentheses.
285
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#parens-as-args'
286
+ Enabled: true
287
+
288
+ Lint/AmbiguousRegexpLiteral:
289
+ Description: >-
290
+ Checks for ambiguous regexp literals in the first argument of
291
+ a method invocation without parenthesis.
292
+ Enabled: true
293
+
294
+ Lint/AssignmentInCondition:
295
+ Description: "Don't use assignment in conditions."
296
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#safe-assignment-in-condition'
297
+ Enabled: true
298
+
299
+ Layout/BlockAlignment:
300
+ Description: 'Align block ends correctly.'
301
+ Enabled: true
302
+
303
+ Lint/CircularArgumentReference:
304
+ Description: "Don't refer to the keyword argument in the default value."
305
+ Enabled: true
306
+
307
+ Layout/ConditionPosition:
308
+ Description: >-
309
+ Checks for condition placed in a confusing position relative to
310
+ the keyword.
311
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#same-line-condition'
312
+ Enabled: true
313
+
314
+ Lint/Debugger:
315
+ Description: 'Check for debugger calls.'
316
+ Enabled: true
317
+
318
+ Layout/DefEndAlignment:
319
+ Description: 'Align ends corresponding to defs correctly.'
320
+ Enabled: true
321
+
322
+ Lint/DeprecatedClassMethods:
323
+ Description: 'Check for deprecated class method calls.'
324
+ Enabled: true
325
+
326
+ Lint/DuplicateMethods:
327
+ Description: 'Check for duplicate methods calls.'
328
+ Enabled: true
329
+
330
+ Lint/EachWithObjectArgument:
331
+ Description: 'Check for immutable argument given to each_with_object.'
332
+ Enabled: true
333
+
334
+ Lint/ElseLayout:
335
+ Description: 'Check for odd code arrangement in an else block.'
336
+ Enabled: true
337
+
338
+ Lint/EmptyEnsure:
339
+ Description: 'Checks for empty ensure block.'
340
+ Enabled: true
341
+
342
+ Lint/EmptyInterpolation:
343
+ Description: 'Checks for empty string interpolation.'
344
+ Enabled: true
345
+
346
+ Layout/EndAlignment:
347
+ Description: 'Align ends correctly.'
348
+ Enabled: true
349
+
350
+ Lint/EndInMethod:
351
+ Description: 'END blocks should not be placed inside method definitions.'
352
+ Enabled: true
353
+
354
+ Lint/EnsureReturn:
355
+ Description: 'Do not use return in an ensure block.'
356
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-return-ensure'
357
+ Enabled: true
358
+
359
+ Lint/FormatParameterMismatch:
360
+ Description: 'The number of parameters to format/sprint must match the fields.'
361
+ Enabled: true
362
+
363
+ Lint/HandleExceptions:
364
+ Description: "Don't suppress exception."
365
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#dont-hide-exceptions'
366
+ Enabled: true
367
+
368
+ Lint/LiteralAsCondition:
369
+ Description: 'Checks of literals used in conditions.'
370
+ Enabled: true
371
+
372
+ Lint/LiteralInInterpolation:
373
+ Description: 'Checks for literals used in interpolation.'
374
+ Enabled: true
375
+
376
+ Lint/Loop:
377
+ Description: >-
378
+ Use Kernel#loop with break rather than begin/end/until or
379
+ begin/end/while for post-loop tests.
380
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#loop-with-break'
381
+ Enabled: true
382
+
383
+ Lint/NestedMethodDefinition:
384
+ Description: 'Do not use nested method definitions.'
385
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-nested-methods'
386
+ Enabled: true
387
+
388
+ Lint/NonLocalExitFromIterator:
389
+ Description: 'Do not use return in iterator to cause non-local exit.'
390
+ Enabled: true
391
+
392
+ Lint/ParenthesesAsGroupedExpression:
393
+ Description: >-
394
+ Checks for method calls with a space before the opening
395
+ parenthesis.
396
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#parens-no-spaces'
397
+ Enabled: true
398
+
399
+ Lint/RequireParentheses:
400
+ Description: >-
401
+ Use parentheses in the method call to avoid confusion
402
+ about precedence.
403
+ Enabled: true
404
+
405
+ Lint/RescueException:
406
+ Description: 'Avoid rescuing the Exception class.'
407
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-blind-rescues'
408
+ Enabled: true
409
+
410
+ Lint/ShadowingOuterLocalVariable:
411
+ Description: >-
412
+ Do not use the same name as outer local variable
413
+ for block arguments or block local variables.
414
+ Enabled: true
415
+
416
+ Lint/StringConversionInInterpolation:
417
+ Description: 'Checks for Object#to_s usage in string interpolation.'
418
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-to-s'
419
+ Enabled: true
420
+
421
+ Lint/UnderscorePrefixedVariableName:
422
+ Description: 'Do not use prefix `_` for a variable that is used.'
423
+ Enabled: true
424
+
425
+ Lint/UnneededCopDisableDirective:
426
+ Description: >-
427
+ Checks for rubocop:disable comments that can be removed.
428
+ Note: this cop is not disabled when disabling all cops.
429
+ It must be explicitly disabled.
430
+ Enabled: true
431
+
432
+ Lint/UnusedBlockArgument:
433
+ Description: 'Checks for unused block arguments.'
434
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#underscore-unused-vars'
435
+ Enabled: true
436
+
437
+ Lint/UnusedMethodArgument:
438
+ Description: 'Checks for unused method arguments.'
439
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#underscore-unused-vars'
440
+ Enabled: true
441
+
442
+ Lint/UnreachableCode:
443
+ Description: 'Unreachable code.'
444
+ Enabled: true
445
+
446
+ Lint/UselessAccessModifier:
447
+ Description: 'Checks for useless access modifiers.'
448
+ Enabled: true
449
+
450
+ Lint/UselessAssignment:
451
+ Description: 'Checks for useless assignment to a local variable.'
452
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#underscore-unused-vars'
453
+ Enabled: true
454
+
455
+ Lint/UselessComparison:
456
+ Description: 'Checks for comparison of something with itself.'
457
+ Enabled: true
458
+
459
+ Lint/UselessElseWithoutRescue:
460
+ Description: 'Checks for useless `else` in `begin..end` without `rescue`.'
461
+ Enabled: true
462
+
463
+ Lint/UselessSetterCall:
464
+ Description: 'Checks for useless setter call to a local variable.'
465
+ Enabled: true
466
+
467
+ Lint/Void:
468
+ Description: 'Possible use of operator/literal/variable in void context.'
469
+ Enabled: true
470
+
471
+ ###################### Metrics ####################################
472
+
473
+ Metrics/AbcSize:
474
+ Description: >-
475
+ A calculated magnitude based on number of assignments,
476
+ branches, and conditions.
477
+ Reference: 'http://c2.com/cgi/wiki?AbcMetric'
478
+ Enabled: true
479
+ Max: 20
480
+
481
+ Metrics/BlockNesting:
482
+ Description: 'Avoid excessive block nesting'
483
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#three-is-the-number-thou-shalt-count'
484
+ Enabled: true
485
+ Max: 4
486
+
487
+ Metrics/ClassLength:
488
+ Description: 'Avoid classes longer than 250 lines of code.'
489
+ Enabled: true
490
+ Max: 250
491
+
492
+ Metrics/CyclomaticComplexity:
493
+ Description: >-
494
+ A complexity metric that is strongly correlated to the number
495
+ of test cases needed to validate a method.
496
+ Enabled: true
497
+
498
+ Metrics/LineLength:
499
+ Description: 'Limit lines to 80 characters.'
500
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#80-character-limits'
501
+ Enabled: false
502
+
503
+ Metrics/MethodLength:
504
+ Description: 'Avoid methods longer than 30 lines of code.'
505
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#short-methods'
506
+ Enabled: true
507
+ Max: 30
508
+
509
+ Metrics/ModuleLength:
510
+ Description: 'Avoid modules longer than 250 lines of code.'
511
+ Enabled: true
512
+ Max: 250
513
+
514
+ Metrics/ParameterLists:
515
+ Description: 'Avoid parameter lists longer than three or four parameters.'
516
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#too-many-params'
517
+ Enabled: true
518
+
519
+ Metrics/PerceivedComplexity:
520
+ Description: >-
521
+ A complexity metric geared towards measuring complexity for a
522
+ human reader.
523
+ Enabled: true
524
+
525
+ ##################### Performance #############################
526
+
527
+ Performance/Count:
528
+ Description: >-
529
+ Use `count` instead of `select...size`, `reject...size`,
530
+ `select...count`, `reject...count`, `select...length`,
531
+ and `reject...length`.
532
+ Enabled: true
533
+
534
+ Performance/Detect:
535
+ Description: >-
536
+ Use `detect` instead of `select.first`, `find_all.first`,
537
+ `select.last`, and `find_all.last`.
538
+ Reference: 'https://github.com/JuanitoFatas/fast-ruby#enumerabledetect-vs-enumerableselectfirst-code'
539
+ Enabled: true
540
+
541
+ Performance/FlatMap:
542
+ Description: >-
543
+ Use `Enumerable#flat_map`
544
+ instead of `Enumerable#map...Array#flatten(1)`
545
+ or `Enumberable#collect..Array#flatten(1)`
546
+ Reference: 'https://github.com/JuanitoFatas/fast-ruby#enumerablemaparrayflatten-vs-enumerableflat_map-code'
547
+ Enabled: true
548
+ EnabledForFlattenWithoutParams: false
549
+ # If enabled, this cop will warn about usages of
550
+ # `flatten` being called without any parameters.
551
+ # This can be dangerous since `flat_map` will only flatten 1 level, and
552
+ # `flatten` without any parameters can flatten multiple levels.
553
+
554
+ Performance/ReverseEach:
555
+ Description: 'Use `reverse_each` instead of `reverse.each`.'
556
+ Reference: 'https://github.com/JuanitoFatas/fast-ruby#enumerablereverseeach-vs-enumerablereverse_each-code'
557
+ Enabled: true
558
+
559
+ Performance/Sample:
560
+ Description: >-
561
+ Use `sample` instead of `shuffle.first`,
562
+ `shuffle.last`, and `shuffle[Fixnum]`.
563
+ Reference: 'https://github.com/JuanitoFatas/fast-ruby#arrayshufflefirst-vs-arraysample-code'
564
+ Enabled: true
565
+
566
+ Performance/Size:
567
+ Description: >-
568
+ Use `size` instead of `count` for counting
569
+ the number of elements in `Array` and `Hash`.
570
+ Reference: 'https://github.com/JuanitoFatas/fast-ruby#arraycount-vs-arraysize-code'
571
+ Enabled: true
572
+
573
+ Performance/StringReplacement:
574
+ Description: >-
575
+ Use `tr` instead of `gsub` when you are replacing the same
576
+ number of characters. Use `delete` instead of `gsub` when
577
+ you are deleting characters.
578
+ Reference: 'https://github.com/JuanitoFatas/fast-ruby#stringgsub-vs-stringtr-code'
579
+ Enabled: true
580
+
581
+ ##################### Rails ##################################
582
+
583
+ Rails/ActionFilter:
584
+ Description: 'Enforces consistent use of action filter methods.'
585
+ Enabled: false
586
+
587
+ Rails/Date:
588
+ Description: >-
589
+ Checks the correct usage of date aware methods,
590
+ such as Date.today, Date.current etc.
591
+ Enabled: false
592
+
593
+ Rails/Delegate:
594
+ Description: 'Prefer delegate method for delegations.'
595
+ Enabled: false
596
+
597
+ Rails/FindBy:
598
+ Description: 'Prefer find_by over where.first.'
599
+ Enabled: false
600
+
601
+ Rails/FindEach:
602
+ Description: 'Prefer all.find_each over all.find.'
603
+ Enabled: false
604
+
605
+ Rails/HasAndBelongsToMany:
606
+ Description: 'Prefer has_many :through to has_and_belongs_to_many.'
607
+ Enabled: false
608
+
609
+ Rails/Output:
610
+ Description: 'Checks for calls to puts, print, etc.'
611
+ Enabled: false
612
+
613
+ Rails/ReadWriteAttribute:
614
+ Description: >-
615
+ Checks for read_attribute(:attr) and
616
+ write_attribute(:attr, val).
617
+ Enabled: false
618
+
619
+ Rails/ScopeArgs:
620
+ Description: 'Checks the arguments of ActiveRecord scopes.'
621
+ Enabled: false
622
+
623
+ Rails/TimeZone:
624
+ Description: 'Checks the correct usage of time zone aware methods.'
625
+ StyleGuide: 'https://github.com/bbatsov/rails-style-guide#time'
626
+ Reference: 'http://danilenko.org/2012/7/6/rails_timezones'
627
+ Enabled: false
628
+
629
+ Rails/Validation:
630
+ Description: 'Use validates :attribute, hash of validations.'
631
+ Enabled: false
632
+
633
+ ################## Style #################################
634
+
635
+ Naming/AccessorMethodName:
636
+ Description: Check the naming of accessor methods for get_/set_.
637
+ Enabled: false
638
+
639
+ Style/Alias:
640
+ Description: 'Use alias_method instead of alias.'
641
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#alias-method'
642
+ Enabled: false
643
+
644
+ Style/AndOr:
645
+ Description: 'Use &&/|| instead of and/or.'
646
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-and-or-or'
647
+ Enabled: false
648
+
649
+ Style/ArrayJoin:
650
+ Description: 'Use Array#join instead of Array#*.'
651
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#array-join'
652
+ Enabled: false
653
+
654
+ Style/AsciiComments:
655
+ Description: 'Use only ascii symbols in comments.'
656
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#english-comments'
657
+ Enabled: false
658
+
659
+ Naming/AsciiIdentifiers:
660
+ Description: 'Use only ascii symbols in identifiers.'
661
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#english-identifiers'
662
+ Enabled: false
663
+
664
+ Style/Attr:
665
+ Description: 'Checks for uses of Module#attr.'
666
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#attr'
667
+ Enabled: false
668
+
669
+ Style/BeginBlock:
670
+ Description: 'Avoid the use of BEGIN blocks.'
671
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-BEGIN-blocks'
672
+ Enabled: false
673
+
674
+ Style/BarePercentLiterals:
675
+ Description: 'Checks if usage of %() or %Q() matches configuration.'
676
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#percent-q-shorthand'
677
+ Enabled: false
678
+
679
+ Style/BlockComments:
680
+ Description: 'Do not use block comments.'
681
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-block-comments'
682
+ Enabled: false
683
+
684
+ Style/BlockDelimiters:
685
+ Description: >-
686
+ Avoid using {...} for multi-line blocks (multiline chaining is
687
+ always ugly).
688
+ Prefer {...} over do...end for single-line blocks.
689
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#single-line-blocks'
690
+ Enabled: false
691
+
692
+ Style/BracesAroundHashParameters:
693
+ Description: 'Enforce braces style around hash parameters.'
694
+ Enabled: false
695
+
696
+ Style/CaseEquality:
697
+ Description: 'Avoid explicit use of the case equality operator(===).'
698
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-case-equality'
699
+ Enabled: false
700
+
701
+ Style/CharacterLiteral:
702
+ Description: 'Checks for uses of character literals.'
703
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-character-literals'
704
+ Enabled: false
705
+
706
+ Naming/ClassAndModuleCamelCase:
707
+ Description: 'Use CamelCase for classes and modules.'
708
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#camelcase-classes'
709
+ Enabled: false
710
+
711
+ Style/ClassAndModuleChildren:
712
+ Description: 'Checks style of children classes and modules.'
713
+ Enabled: false
714
+
715
+ Style/ClassCheck:
716
+ Description: 'Enforces consistent use of `Object#is_a?` or `Object#kind_of?`.'
717
+ Enabled: false
718
+
719
+ Style/ClassMethods:
720
+ Description: 'Use self when defining module/class methods.'
721
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#def-self-class-methods'
722
+ Enabled: false
723
+
724
+ Style/ClassVars:
725
+ Description: 'Avoid the use of class variables.'
726
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-class-vars'
727
+ Enabled: false
728
+
729
+ Style/ColonMethodCall:
730
+ Description: 'Do not use :: for method call.'
731
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#double-colons'
732
+ Enabled: false
733
+
734
+ Style/CommandLiteral:
735
+ Description: 'Use `` or %x around command literals.'
736
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#percent-x'
737
+ Enabled: false
738
+
739
+ Style/CommentAnnotation:
740
+ Description: 'Checks formatting of annotation comments.'
741
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#annotate-keywords'
742
+ Enabled: false
743
+
744
+ Naming/ConstantName:
745
+ Description: 'Constants should use SCREAMING_SNAKE_CASE.'
746
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#screaming-snake-case'
747
+ Enabled: false
748
+
749
+ Style/DefWithParentheses:
750
+ Description: 'Use def with parentheses when there are arguments.'
751
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#method-parens'
752
+ Enabled: false
753
+
754
+ Style/PreferredHashMethods:
755
+ Description: 'Checks for use of deprecated Hash methods.'
756
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#hash-key'
757
+ Enabled: false
758
+
759
+ Style/Documentation:
760
+ Description: 'Document classes and non-namespace modules.'
761
+ Enabled: false
762
+
763
+ Style/DoubleNegation:
764
+ Description: 'Checks for uses of double negation (!!).'
765
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-bang-bang'
766
+ Enabled: false
767
+
768
+ Style/EachWithObject:
769
+ Description: 'Prefer `each_with_object` over `inject` or `reduce`.'
770
+ Enabled: false
771
+
772
+ Style/EmptyElse:
773
+ Description: 'Avoid empty else-clauses.'
774
+ Enabled: false
775
+
776
+ Style/EmptyLiteral:
777
+ Description: 'Prefer literals to Array.new/Hash.new/String.new.'
778
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#literal-array-hash'
779
+ Enabled: false
780
+
781
+ Style/EndBlock:
782
+ Description: 'Avoid the use of END blocks.'
783
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-END-blocks'
784
+ Enabled: false
785
+
786
+ Style/EvenOdd:
787
+ Description: 'Favor the use of Fixnum#even? && Fixnum#odd?'
788
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#predicate-methods'
789
+ Enabled: false
790
+
791
+ Naming/FileName:
792
+ Description: 'Use snake_case for source file names.'
793
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#snake-case-files'
794
+ Enabled: false
795
+
796
+ Style/FlipFlop:
797
+ Description: 'Checks for flip flops'
798
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-flip-flops'
799
+ Enabled: false
800
+
801
+ Style/For:
802
+ Description: 'Checks use of for or each in multiline loops.'
803
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-for-loops'
804
+ Enabled: false
805
+
806
+ Style/FormatString:
807
+ Description: 'Enforce the use of Kernel#sprintf, Kernel#format or String#%.'
808
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#sprintf'
809
+ Enabled: false
810
+
811
+ Style/GlobalVars:
812
+ Description: 'Do not introduce global variables.'
813
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#instance-vars'
814
+ Reference: 'http://www.zenspider.com/Languages/Ruby/QuickRef.html'
815
+ Enabled: false
816
+
817
+ Style/GuardClause:
818
+ Description: 'Check for conditionals that can be replaced with guard clauses'
819
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-nested-conditionals'
820
+ Enabled: false
821
+
822
+ Style/HashSyntax:
823
+ Description: >-
824
+ Prefer Ruby 1.9 hash syntax { a: 1, b: 2 } over 1.8 syntax
825
+ { :a => 1, :b => 2 }.
826
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#hash-literals'
827
+ Enabled: false
828
+
829
+ Style/IfUnlessModifier:
830
+ Description: >-
831
+ Favor modifier if/unless usage when you have a
832
+ single-line body.
833
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#if-as-a-modifier'
834
+ Enabled: false
835
+
836
+ Style/IfWithSemicolon:
837
+ Description: 'Do not use if x; .... Use the ternary operator instead.'
838
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-semicolon-ifs'
839
+ Enabled: false
840
+
841
+ Style/InfiniteLoop:
842
+ Description: 'Use Kernel#loop for infinite loops.'
843
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#infinite-loop'
844
+ Enabled: false
845
+
846
+ Style/Lambda:
847
+ Description: 'Use the new lambda literal syntax for single-line blocks.'
848
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#lambda-multi-line'
849
+ Enabled: false
850
+
851
+ Style/LambdaCall:
852
+ Description: 'Use lambda.call(...) instead of lambda.(...).'
853
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#proc-call'
854
+ Enabled: false
855
+
856
+ Style/LineEndConcatenation:
857
+ Description: >-
858
+ Use \ instead of + or << to concatenate two string literals at
859
+ line end.
860
+ Enabled: false
861
+
862
+ Style/MethodCallWithoutArgsParentheses:
863
+ Description: 'Do not use parentheses for method calls with no arguments.'
864
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-args-no-parens'
865
+ Enabled: true
866
+
867
+ Style/MethodDefParentheses:
868
+ Description: >-
869
+ Checks if the method definitions have or don't have
870
+ parentheses.
871
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#method-parens'
872
+ Enabled: false
873
+
874
+ Naming/MethodName:
875
+ Description: 'Use the configured style when naming methods.'
876
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#snake-case-symbols-methods-vars'
877
+ Enabled: false
878
+
879
+ Style/ModuleFunction:
880
+ Description: 'Checks for usage of `extend self` in modules.'
881
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#module-function'
882
+ Enabled: false
883
+
884
+ Style/MultilineBlockChain:
885
+ Description: 'Avoid multi-line chains of blocks.'
886
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#single-line-blocks'
887
+ Enabled: false
888
+
889
+ Style/MultilineIfThen:
890
+ Description: 'Do not use then for multi-line if/unless.'
891
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-then'
892
+ Enabled: false
893
+
894
+ Style/MultilineTernaryOperator:
895
+ Description: >-
896
+ Avoid multi-line ?: (the ternary operator);
897
+ use if/unless instead.
898
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-multiline-ternary'
899
+ Enabled: false
900
+
901
+ Style/NegatedIf:
902
+ Description: >-
903
+ Favor unless over if for negative conditions
904
+ (or control flow or).
905
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#unless-for-negatives'
906
+ Enabled: false
907
+
908
+ Style/NegatedWhile:
909
+ Description: 'Favor until over while for negative conditions.'
910
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#until-for-negatives'
911
+ Enabled: false
912
+
913
+ Style/NestedTernaryOperator:
914
+ Description: 'Use one expression per branch in a ternary operator.'
915
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-nested-ternary'
916
+ Enabled: false
917
+
918
+ Style/Next:
919
+ Description: 'Use `next` to skip iteration instead of a condition at the end.'
920
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-nested-conditionals'
921
+ Enabled: false
922
+
923
+ Style/NilComparison:
924
+ Description: 'Prefer x.nil? to x == nil.'
925
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#predicate-methods'
926
+ Enabled: false
927
+
928
+ Style/NonNilCheck:
929
+ Description: 'Checks for redundant nil checks.'
930
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-non-nil-checks'
931
+ Enabled: false
932
+
933
+ Style/Not:
934
+ Description: 'Use ! instead of not.'
935
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#bang-not-not'
936
+ Enabled: false
937
+
938
+ Style/NumericLiterals:
939
+ Description: >-
940
+ Add underscores to large numeric literals to improve their
941
+ readability.
942
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#underscores-in-numerics'
943
+ Enabled: false
944
+
945
+ Style/OneLineConditional:
946
+ Description: >-
947
+ Favor the ternary operator(?:) over
948
+ if/then/else/end constructs.
949
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#ternary-operator'
950
+ Enabled: false
951
+
952
+ Naming/BinaryOperatorParameterName:
953
+ Description: 'When defining binary operators, name the argument other.'
954
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#other-arg'
955
+ Enabled: false
956
+
957
+ Style/OptionalArguments:
958
+ Description: >-
959
+ Checks for optional arguments that do not appear at the end
960
+ of the argument list
961
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#optional-arguments'
962
+ Enabled: false
963
+
964
+ Style/ParallelAssignment:
965
+ Description: >-
966
+ Check for simple usages of parallel assignment.
967
+ It will only warn when the number of variables
968
+ matches on both sides of the assignment.
969
+ This also provides performance benefits
970
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#parallel-assignment'
971
+ Enabled: false
972
+
973
+ Style/ParenthesesAroundCondition:
974
+ Description: >-
975
+ Don't use parentheses around the condition of an
976
+ if/unless/while.
977
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-parens-if'
978
+ Enabled: false
979
+
980
+ Style/PercentLiteralDelimiters:
981
+ Description: 'Use `%`-literal delimiters consistently'
982
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#percent-literal-braces'
983
+ Enabled: false
984
+
985
+ Style/PercentQLiterals:
986
+ Description: 'Checks if uses of %Q/%q match the configured preference.'
987
+ Enabled: false
988
+
989
+ Style/PerlBackrefs:
990
+ Description: 'Avoid Perl-style regex back references.'
991
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-perl-regexp-last-matchers'
992
+ Enabled: false
993
+
994
+ Naming/PredicateName:
995
+ Description: 'Check the names of predicate methods.'
996
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#bool-methods-qmark'
997
+ Enabled: false
998
+
999
+ Style/Proc:
1000
+ Description: 'Use proc instead of Proc.new.'
1001
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#proc'
1002
+ Enabled: false
1003
+
1004
+ Style/RaiseArgs:
1005
+ Description: 'Checks the arguments passed to raise/fail.'
1006
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#exception-class-messages'
1007
+ Enabled: false
1008
+
1009
+ Style/RedundantBegin:
1010
+ Description: "Don't use begin blocks when they are not needed."
1011
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#begin-implicit'
1012
+ Enabled: false
1013
+
1014
+ Style/RedundantException:
1015
+ Description: "Checks for an obsolete RuntimeException argument in raise/fail."
1016
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-explicit-runtimeerror'
1017
+ Enabled: false
1018
+
1019
+ Style/RedundantReturn:
1020
+ Description: "Don't use return where it's not required."
1021
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-explicit-return'
1022
+ Enabled: false
1023
+
1024
+ Style/RedundantSelf:
1025
+ Description: "Don't use self where it's not needed."
1026
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-self-unless-required'
1027
+ Enabled: false
1028
+
1029
+ Style/RegexpLiteral:
1030
+ Description: 'Use / or %r around regular expressions.'
1031
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#percent-r'
1032
+ Enabled: false
1033
+
1034
+ Style/RescueModifier:
1035
+ Description: 'Avoid using rescue in its modifier form.'
1036
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-rescue-modifiers'
1037
+ Enabled: false
1038
+
1039
+ Style/SelfAssignment:
1040
+ Description: >-
1041
+ Checks for places where self-assignment shorthand should have
1042
+ been used.
1043
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#self-assignment'
1044
+ Enabled: false
1045
+
1046
+ Style/Semicolon:
1047
+ Description: "Don't use semicolons to terminate expressions."
1048
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-semicolon'
1049
+ Enabled: false
1050
+
1051
+ Style/SignalException:
1052
+ Description: 'Checks for proper usage of fail and raise.'
1053
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#fail-method'
1054
+ Enabled: false
1055
+
1056
+ Style/SingleLineBlockParams:
1057
+ Description: 'Enforces the names of some block params.'
1058
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#reduce-blocks'
1059
+ Enabled: false
1060
+
1061
+ Style/SingleLineMethods:
1062
+ Description: 'Avoid single-line methods.'
1063
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-single-line-methods'
1064
+ Enabled: false
1065
+
1066
+ Style/SpecialGlobalVars:
1067
+ Description: 'Avoid Perl-style global variables.'
1068
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-cryptic-perlisms'
1069
+ Enabled: false
1070
+
1071
+ Style/StringLiterals:
1072
+ Description: 'Checks if uses of quotes match the configured preference.'
1073
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#consistent-string-literals'
1074
+ Enabled: false
1075
+
1076
+ Style/StringLiteralsInInterpolation:
1077
+ Description: >-
1078
+ Checks if uses of quotes inside expressions in interpolated
1079
+ strings match the configured preference.
1080
+ Enabled: false
1081
+
1082
+ Style/StructInheritance:
1083
+ Description: 'Checks for inheritance from Struct.new.'
1084
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-extend-struct-new'
1085
+ Enabled: false
1086
+
1087
+ Style/SymbolLiteral:
1088
+ Description: 'Use plain symbols instead of string symbols when possible.'
1089
+ Enabled: false
1090
+
1091
+ Style/SymbolProc:
1092
+ Description: 'Use symbols as procs instead of blocks when possible.'
1093
+ Enabled: false
1094
+
1095
+ Style/TrailingCommaInArguments:
1096
+ Description: 'Checks for trailing comma in parameter lists.'
1097
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-trailing-params-comma'
1098
+ Enabled: false
1099
+
1100
+ Style/TrailingCommaInArrayLiteral:
1101
+ Description: 'Checks for trailing comma in array literals.'
1102
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-trailing-array-commas'
1103
+ Enabled: false
1104
+
1105
+ Style/TrailingCommaInHashLiteral:
1106
+ Description: 'Checks for trailing comma in hash literals.'
1107
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-trailing-array-commas'
1108
+ Enabled: false
1109
+
1110
+ Style/TrivialAccessors:
1111
+ Description: 'Prefer attr_* methods to trivial readers/writers.'
1112
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#attr_family'
1113
+ Enabled: false
1114
+
1115
+ Style/UnlessElse:
1116
+ Description: >-
1117
+ Do not use unless with else. Rewrite these with the positive
1118
+ case first.
1119
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-else-with-unless'
1120
+ Enabled: false
1121
+
1122
+ Style/UnneededCapitalW:
1123
+ Description: 'Checks for %W when interpolation is not needed.'
1124
+ Enabled: false
1125
+
1126
+ Style/UnneededPercentQ:
1127
+ Description: 'Checks for %q/%Q when single quotes or double quotes would do.'
1128
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#percent-q'
1129
+ Enabled: false
1130
+
1131
+ Style/TrailingUnderscoreVariable:
1132
+ Description: >-
1133
+ Checks for the usage of unneeded trailing underscores at the
1134
+ end of parallel variable assignment.
1135
+ Enabled: false
1136
+
1137
+ Style/VariableInterpolation:
1138
+ Description: >-
1139
+ Don't interpolate global, instance and class variables
1140
+ directly in strings.
1141
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#curlies-interpolate'
1142
+ Enabled: false
1143
+
1144
+ Naming/VariableName:
1145
+ Description: 'Use the configured style when naming variables.'
1146
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#snake-case-symbols-methods-vars'
1147
+ Enabled: false
1148
+
1149
+ Style/WhenThen:
1150
+ Description: 'Use when x then ... for one-line cases.'
1151
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#one-line-cases'
1152
+ Enabled: false
1153
+
1154
+ Style/WhileUntilDo:
1155
+ Description: 'Checks for redundant do after while or until.'
1156
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-multiline-while-do'
1157
+ Enabled: false
1158
+
1159
+ Style/WhileUntilModifier:
1160
+ Description: >-
1161
+ Favor modifier while/until usage when you have a
1162
+ single-line body.
1163
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#while-as-a-modifier'
1164
+ Enabled: false
1165
+
1166
+ Style/WordArray:
1167
+ Description: 'Use %w or %W for arrays of words.'
1168
+ StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#percent-w'
1169
+ Enabled: false
1170
+
1171
+ #################### Security ################################
1172
+
1173
+ Security/Eval:
1174
+ Description: 'The use of eval represents a serious security risk.'
1175
+ Enabled: true