devise_materialize 1.0.0 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f6edab3efebd8ea1398d6203bb803c4ac827363c
4
- data.tar.gz: 86a8cd60a0424269febdacfe04611b3ea8484282
3
+ metadata.gz: 1d3252ef7b61963b55bcc684ac7f4b77f1a5b03f
4
+ data.tar.gz: 7de33b4116b68a1b83be7654fdbc68d2021819ce
5
5
  SHA512:
6
- metadata.gz: f05c608e084fde346043e1d6b066cc029af6e37e1154a7704d97a28160dcb6d3fb2336550112ce0b9f180d037d81e94c1a5f7623a7391e0429ee671b179aa787
7
- data.tar.gz: db1a2deabc15ed004874de15b07e9a7fdfd78059a6dfd4d86e67947cd67e170bc8acdf78166bbf76fb7cd9652391fafeb49b64a36ed2fe0ad270a128a3e25ab3
6
+ metadata.gz: d9348d41e6da94bc6584b0c2c3ab26a19d9941e3c2f9a19bb1440cb6a074301576ea72eee08afa65dbc9780c81de589e9733c2ef80e9038c209ac92c5ef4e104
7
+ data.tar.gz: 8d96d4f82c745ebf01a92546aab686a60e279f4f3652e92b0b9b540ea6513886b8489cf3c0189d4ac979a1ec6be1de12116b10bbe93ec764aad434edfce07096
@@ -0,0 +1,54 @@
1
+ # Ruby CircleCI 2.0 configuration file
2
+ #
3
+ # Check https://circleci.com/docs/2.0/language-ruby/ for more details
4
+ #
5
+ version: 2
6
+ jobs:
7
+ build:
8
+ docker:
9
+ # specify the version you desire here
10
+ - image: circleci/ruby:2.4.1
11
+ environment:
12
+ RAILS_ENV: test
13
+
14
+ working_directory: ~/devise_materialize
15
+
16
+ steps:
17
+ - checkout
18
+
19
+ # Download and cache dependencies
20
+ - restore_cache:
21
+ keys:
22
+ - v1-dependencies-{{ checksum "Gemfile.lock" }}
23
+
24
+ - run:
25
+ name: Install Gems
26
+ command: |
27
+ bundle install --jobs=4 --retry=3 --path vendor/bundle
28
+
29
+ - save_cache:
30
+ paths:
31
+ - ./vendor/bundle
32
+ key: v1-dependencies-{{ checksum "Gemfile.lock" }}
33
+
34
+ # run tests!
35
+ - run:
36
+ name: Run Tests
37
+ command: |
38
+ bundle exec rake test
39
+
40
+ - run:
41
+ name: Install Gems for Global Usage
42
+ command: |
43
+ gem install rubocop
44
+
45
+ - run:
46
+ name: Run Linters
47
+ command: |
48
+ bundle exec rake rubocop
49
+ bundle exec codeclimate-test-reporter
50
+
51
+ # collect reports
52
+ - store_artifacts:
53
+ path: coverage
54
+ destination: coverage
@@ -0,0 +1,17 @@
1
+ ## How to contribute to Ruby on Rails
2
+
3
+ #### **Did you find a bug?**
4
+
5
+ * **Ensure the bug was not already reported** by searching on GitHub under [Issues](https://github.com/techgurupezza/simple_form_materialize/issues).
6
+
7
+ * If you're unable to find an open issue addressing the problem, [open a new one](https://github.com/techgurupezza/simple_form_materialize/issues/new). Be sure to include a **title and clear description**, as much relevant information as possible, and a **code sample** or an **executable test case** demonstrating the expected behavior that is not occurring.
8
+
9
+ #### **Did you write a patch that fixes a bug?**
10
+
11
+ * Open a new GitHub pull request with the patch.
12
+
13
+ * Ensure the PR description clearly describes the problem and solution. Include the relevant issue number if applicable.
14
+
15
+ Thanks!
16
+
17
+ Repo Owner
@@ -0,0 +1,21 @@
1
+ ## Expected Behavior
2
+
3
+
4
+ ## Actual Behavior
5
+
6
+
7
+ ## Steps to Reproduce
8
+
9
+
10
+ ## Browsers Used
11
+ - [ ] Explorer
12
+ - [ ] Chrome
13
+ - [ ] Firefox
14
+ - [ ] Edge
15
+ - [ ] Opera
16
+
17
+
18
+ ## OS Used
19
+ - [ ] Linux
20
+ - [ ] Mac
21
+ - [ ] Windows
@@ -0,0 +1,9 @@
1
+ ## Feature Enhancements Added
2
+ List out Issue Numbers below in a list
3
+
4
+
5
+ ## Bugs Fixed
6
+ List out Issue Numbers below in a list
7
+
8
+
9
+ ## Description of overall changes
@@ -1,865 +1,1747 @@
1
- ---
2
1
  AllCops:
3
2
  Exclude:
4
- - vendor/**/*
5
- - db/**/*
6
- - Gemfile.lock
7
- - devise_materialize.gemspec
8
- - Rakefile
9
- - test/rails_app/**/*
3
+ - vendor/**/*
4
+ - Gemfile.lock
5
+ - db/schema.rb
6
+ - node_modules/**/*
7
+ - simple_form_materialize.gemspec
8
+ - test/rails_app/**/*
9
+ - test/tmp/**/*
10
+ - lib/generators/templates/**/*
10
11
  TargetRubyVersion: 2.4
12
+
13
+ # Department Bundler
14
+ Bundler/DuplicatedGem:
15
+ Description: Checks for duplicate gem entries in Gemfile.
16
+ Enabled: true
17
+
18
+ Bundler/InsecureProtocolSource:
19
+ Description: The source `:gemcutter`, `:rubygems` and `:rubyforge` are deprecated because HTTP requests are insecure. Please change your source to 'https://rubygems.org' if possible, or 'http://rubygems.org' if not.
20
+ Enabled: true
21
+
22
+ Bundler/OrderedGems:
23
+ Description: Gems within groups in the Gemfile should be alphabetically sorted.
24
+ Enabled: true
25
+
26
+ # Department Gemspec
27
+ Gemspec/OrderedDependencies:
28
+ Description: Dependencies in the gemspec should be alphabetically sorted.
29
+ Enabled: true
30
+
31
+ # Department Layout
32
+ Layout/AccessModifierIndentation:
33
+ Description: Check indentation of private/protected visibility modifiers.
34
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#indent-public-private-protected
35
+ Enabled: false
36
+
37
+ Layout/AlignArray:
38
+ Description: Align the elements of an array literal if they span more than one line.
39
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#align-multiline-arrays
40
+ Enabled: true
41
+
42
+ Layout/AlignHash:
43
+ Description: Align the elements of a hash literal if they span more than one line.
44
+ Enabled: true
45
+
46
+ Layout/AlignParameters:
47
+ Description: Align the parameters of a method call if they span more than one line.
48
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-double-indent
49
+ Enabled: true
50
+
51
+ Layout/BlockEndNewline:
52
+ Description: Put end statement of multiline block on its own line.
53
+ Enabled: true
54
+
55
+ Layout/CaseIndentation:
56
+ Description: Indentation of when in a case/when/[else/]end.
57
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#indent-when-to-case
58
+ Enabled: true
59
+
60
+ Layout/ClosingParenthesisIndentation:
61
+ Description: Checks the indentation of hanging closing parentheses.
62
+ Enabled: false
63
+
64
+ Layout/CommentIndentation:
65
+ Description: Indentation of comments.
66
+ Enabled: false
67
+
68
+ Layout/DotPosition:
69
+ Description: Checks the position of the dot in multi-line method calls.
70
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#consistent-multi-line-chains
71
+ Enabled: true
72
+
73
+ Layout/ElseAlignment:
74
+ Description: Align elses and elsifs correctly.
75
+ Enabled: true
76
+
77
+ Layout/EmptyLineBetweenDefs:
78
+ Description: Use empty lines between defs.
79
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#empty-lines-between-methods
80
+ Enabled: true
81
+
82
+ Layout/EmptyLines:
83
+ Description: Don't use several empty lines in a row.
84
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#two-or-more-empty-lines
85
+ Enabled: true
86
+
87
+ Layout/EmptyLinesAroundAccessModifier:
88
+ Description: Keep blank lines around access modifiers.
89
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#empty-lines-around-access-modifier
90
+ Enabled: false
91
+
92
+ Layout/EmptyLinesAroundBeginBody:
93
+ Description: Keeps track of empty lines around begin-end bodies.
94
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#empty-lines-around-bodies
95
+ Enabled: false
96
+
97
+ Layout/EmptyLinesAroundBlockBody:
98
+ Description: Keeps track of empty lines around block bodies.
99
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#empty-lines-around-bodies
100
+ Enabled: false
101
+
102
+ Layout/EmptyLinesAroundClassBody:
103
+ Description: Keeps track of empty lines around class bodies.
104
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#empty-lines-around-bodies
105
+ Enabled: false
106
+
107
+ Layout/EmptyLinesAroundExceptionHandlingKeywords:
108
+ Description: Keeps track of empty lines around exception handling keywords.
109
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#empty-lines-around-bodies
110
+ Enabled: false
111
+
112
+ Layout/EmptyLinesAroundModuleBody:
113
+ Description: Keeps track of empty lines around module bodies.
114
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#empty-lines-around-bodies
115
+ Enabled: false
116
+
117
+ Layout/EmptyLinesAroundMethodBody:
118
+ Description: Keeps track of empty lines around method bodies.
119
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#empty-lines-around-bodies
120
+ Enabled: false
121
+
122
+ Layout/EndOfLine:
123
+ Description: Use Unix-style line endings.
124
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#crlf
125
+ Enabled: false
126
+
127
+ Layout/ExtraSpacing:
128
+ Description: Do not use unnecessary spacing.
129
+ Enabled: true
130
+
131
+ Layout/FirstArrayElementLineBreak:
132
+ Description: Checks for a line break before the first element in a multi-line array.
133
+ Enabled: false
134
+
135
+ Layout/FirstHashElementLineBreak:
136
+ Description: Checks for a line break before the first element in a multi-line hash.
137
+ Enabled: false
138
+
139
+ Layout/FirstMethodArgumentLineBreak:
140
+ Description: Checks for a line break before the first argument in a multi-line method call.
141
+ Enabled: false
142
+
143
+ Layout/FirstMethodParameterLineBreak:
144
+ Description: Checks for a line break before the first parameter in a multi-line method parameter definition.
145
+ Enabled: false
146
+
147
+ Layout/InitialIndentation:
148
+ Description: Checks the indentation of the first non-blank non-comment line in a file.
149
+ Enabled: false
150
+
151
+ Layout/FirstParameterIndentation:
152
+ Description: Checks the indentation of the first parameter in a method call.
153
+ Enabled: false
154
+
155
+ Layout/IndentationConsistency:
156
+ Description: Keep indentation straight.
157
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-indentation
158
+ Enabled: false
159
+
160
+ Layout/IndentationWidth:
161
+ Description: Use 2 spaces for indentation.
162
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-indentation
163
+ Enabled: true
164
+
165
+ Layout/IndentArray:
166
+ Description: Checks the indentation of the first element in an array literal.
167
+ Enabled: false
168
+
169
+ Layout/IndentAssignment:
170
+ Description: Checks the indentation of the first line of the right-hand-side of a multi-line assignment.
171
+ Enabled: true
172
+
173
+ Layout/IndentHash:
174
+ Description: Checks the indentation of the first key in a hash literal.
175
+ Enabled: false
176
+
177
+ Layout/IndentHeredoc:
178
+ Description: This cops checks the indentation of the here document bodies.
179
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#squiggly-heredocs
180
+ Enabled: true
181
+
182
+ Layout/SpaceInLambdaLiteral:
183
+ Description: Checks for spaces in lambda literals.
184
+ Enabled: true
185
+
186
+ Layout/LeadingCommentSpace:
187
+ Description: Comments should start with a space.
188
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#hash-space
189
+ Enabled: true
190
+
191
+ Layout/MultilineArrayBraceLayout:
192
+ Description: Checks that the closing brace in an array literal is either on the same line as the last array element, or a new line.
193
+ Enabled: true
194
+
195
+ Layout/MultilineAssignmentLayout:
196
+ Description: Check for a newline after the assignment operator in multi-line assignments.
197
+ StyleGuide: https://github.com/bbatsov/ruby-style-guid#indent-conditional-assignment
198
+ Enabled: false
199
+
200
+ Layout/MultilineBlockLayout:
201
+ Description: Ensures newlines after multiline block do statements.
202
+ Enabled: true
203
+
204
+ Layout/MultilineHashBraceLayout:
205
+ Description: Checks that the closing brace in a hash literal is either on the same line as the last hash element, or a new line.
206
+ Enabled: true
207
+
208
+ Layout/MultilineMethodCallBraceLayout:
209
+ Description: Checks that the closing brace in a method call is either on the same line as the last method argument, or a new line.
210
+ Enabled: true
211
+
212
+ Layout/MultilineMethodCallIndentation:
213
+ Description: Checks indentation of method calls with the dot operator that span more than one line.
214
+ Enabled: true
215
+
216
+ Layout/MultilineMethodDefinitionBraceLayout:
217
+ Description: Checks that the closing brace in a method definition is either on the same line as the last method parameter, or a new line.
218
+ Enabled: true
219
+
220
+ Layout/MultilineOperationIndentation:
221
+ Description: Checks indentation of binary operations that span more than one line.
222
+ Enabled: false
223
+
224
+ Layout/EmptyLineAfterMagicComment:
225
+ Description: Add an empty line after magic comments to separate them from code.
226
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#separate-magic-comments-from-code
227
+ Enabled: true
228
+
229
+ Layout/RescueEnsureAlignment:
230
+ Description: Align rescues and ensures correctly.
231
+ Enabled: false
232
+
233
+ Layout/SpaceBeforeFirstArg:
234
+ Description: Checks that exactly one space is used between a method name and the first argument for method calls without parentheses.
235
+ Enabled: true
236
+
237
+ Layout/SpaceAfterColon:
238
+ Description: Use spaces after colons.
239
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-operators
240
+ Enabled: true
241
+
242
+ Layout/SpaceAfterComma:
243
+ Description: Use spaces after commas.
244
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-operators
245
+ Enabled: true
246
+
247
+ Layout/SpaceAfterMethodName:
248
+ Description: Do not put a space between a method name and the opening parenthesis in a method definition.
249
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#parens-no-spaces
250
+ Enabled: true
251
+
252
+ Layout/SpaceAfterNot:
253
+ Description: Tracks redundant space after the ! operator.
254
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-space-bang
255
+ Enabled: false
256
+
257
+ Layout/SpaceAfterSemicolon:
258
+ Description: Use spaces after semicolons.
259
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-operators
260
+ Enabled: true
261
+
262
+ Layout/SpaceBeforeBlockBraces:
263
+ Description: Checks that the left block brace has or doesn't have space before it.
264
+ Enabled: false
265
+
266
+ Layout/SpaceBeforeComma:
267
+ Description: No spaces before commas.
268
+ Enabled: false
269
+
270
+ Layout/SpaceBeforeComment:
271
+ Description: Checks for missing space between code and a comment on the same line.
272
+ Enabled: false
273
+
274
+ Layout/SpaceBeforeSemicolon:
275
+ Description: No spaces before semicolons.
276
+ Enabled: false
277
+
278
+ Layout/SpaceInsideBlockBraces:
279
+ Description: Checks that block braces have or don't have surrounding space. For blocks taking parameters, checks that the left brace has or doesn't have trailing space.
280
+ Enabled: false
281
+
282
+ Layout/SpaceAroundBlockParameters:
283
+ Description: Checks the spacing inside and after block parameters pipes.
284
+ Enabled: true
285
+
286
+ Layout/SpaceAroundEqualsInParameterDefault:
287
+ Description: Checks that the equals signs in parameter default assignments have or don't have surrounding space depending on configuration.
288
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-around-equals
289
+ Enabled: true
290
+
291
+ Layout/SpaceAroundKeyword:
292
+ Description: Use a space around keywords if appropriate.
293
+ Enabled: true
294
+
295
+ Layout/SpaceAroundOperators:
296
+ Description: Use a single space around operators.
297
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-operators
298
+ Enabled: true
299
+
300
+ Layout/SpaceInsideArrayPercentLiteral:
301
+ Description: No unnecessary additional spaces between elements in %i/%w literals.
302
+ Enabled: true
303
+
304
+ Layout/SpaceInsidePercentLiteralDelimiters:
305
+ Description: No unnecessary spaces inside delimiters of %i/%w/%x literals.
306
+ Enabled: true
307
+
308
+ Layout/SpaceInsideHashLiteralBraces:
309
+ Description: Use spaces inside hash literal braces - or don't.
310
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-operators
311
+ Enabled: true
312
+
313
+ Layout/SpaceInsideParens:
314
+ Description: No spaces after ( or before ).
315
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-spaces-braces
316
+ Enabled: true
317
+
318
+ Layout/SpaceInsideRangeLiteral:
319
+ Description: No spaces inside range literals.
320
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-space-inside-range-literals
321
+ Enabled: true
322
+
323
+ Layout/SpaceInsideStringInterpolation:
324
+ Description: Checks for padding/surrounding spaces inside string interpolation.
325
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#string-interpolation
326
+ Enabled: false
327
+
328
+ Layout/Tab:
329
+ Description: No hard tabs.
330
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-indentation
331
+ Enabled: false
332
+
333
+ Layout/TrailingBlankLines:
334
+ Description: Checks trailing blank lines and final newline.
335
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#newline-eof
336
+ Enabled: false
337
+
338
+ Layout/TrailingWhitespace:
339
+ Description: Avoid trailing whitespace.
340
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-trailing-whitespace
341
+ Enabled: false
342
+
343
+ # Department Lint
344
+ Lint/AmbiguousBlockAssociation:
345
+ Description: Checks for ambiguous block association with method when param passed without parentheses.
346
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#syntax
347
+ Enabled: false
348
+
11
349
  Lint/AmbiguousOperator:
12
- Description: Checks for ambiguous operators in the first argument of a method invocation
13
- without parentheses.
14
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#parens-as-args
350
+ Description: Checks for ambiguous operators in the first argument of a method invocation without parentheses.
351
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#method-invocation-parens
15
352
  Enabled: true
353
+
16
354
  Lint/AmbiguousRegexpLiteral:
17
- Description: Checks for ambiguous regexp literals in the first argument of a method
18
- invocation without parenthesis.
355
+ Description: Checks for ambiguous regexp literals in the first argument of a method invocation without parentheses.
19
356
  Enabled: true
357
+
20
358
  Lint/AssignmentInCondition:
21
359
  Description: Don't use assignment in conditions.
22
360
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#safe-assignment-in-condition
23
361
  Enabled: true
362
+
24
363
  Lint/BlockAlignment:
25
364
  Description: Align block ends correctly.
26
365
  Enabled: true
366
+
367
+ Lint/BooleanSymbol:
368
+ Description: Check for `:true` and `:false` symbols.
369
+ Enabled: true
370
+
27
371
  Lint/CircularArgumentReference:
28
- Description: Don't refer to the keyword argument in the default value.
372
+ Description: Default values in optional keyword arguments and optional ordinal arguments should not refer back to the name of the argument.
29
373
  Enabled: true
374
+
30
375
  Lint/ConditionPosition:
31
- Description: Checks for condition placed in a confusing position relative to the
32
- keyword.
376
+ Description: Checks for condition placed in a confusing position relative to the keyword.
33
377
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#same-line-condition
34
378
  Enabled: true
379
+
35
380
  Lint/Debugger:
36
381
  Description: Check for debugger calls.
37
382
  Enabled: true
383
+
38
384
  Lint/DefEndAlignment:
39
385
  Description: Align ends corresponding to defs correctly.
40
386
  Enabled: true
387
+
41
388
  Lint/DeprecatedClassMethods:
42
389
  Description: Check for deprecated class method calls.
43
390
  Enabled: true
391
+
392
+ Lint/DuplicateCaseCondition:
393
+ Description: Do not repeat values in case conditionals.
394
+ Enabled: true
395
+
44
396
  Lint/DuplicateMethods:
45
- Description: Check for duplicate methods calls.
397
+ Description: Check for duplicate method definitions.
46
398
  Enabled: true
399
+
400
+ Lint/DuplicatedKey:
401
+ Description: Check for duplicate keys in hash literals.
402
+ Enabled: true
403
+
47
404
  Lint/EachWithObjectArgument:
48
405
  Description: Check for immutable argument given to each_with_object.
49
406
  Enabled: true
407
+
50
408
  Lint/ElseLayout:
51
409
  Description: Check for odd code arrangement in an else block.
52
410
  Enabled: true
411
+
53
412
  Lint/EmptyEnsure:
54
413
  Description: Checks for empty ensure block.
55
414
  Enabled: true
415
+ AutoCorrect: false
416
+
417
+ Lint/EmptyExpression:
418
+ Description: Checks for empty expressions.
419
+ Enabled: true
420
+
56
421
  Lint/EmptyInterpolation:
57
422
  Description: Checks for empty string interpolation.
58
423
  Enabled: true
424
+
425
+ Lint/EmptyWhen:
426
+ Description: Checks for `when` branches with empty bodies.
427
+ Enabled: true
428
+
59
429
  Lint/EndAlignment:
60
430
  Description: Align ends correctly.
61
431
  Enabled: true
432
+
62
433
  Lint/EndInMethod:
63
434
  Description: END blocks should not be placed inside method definitions.
64
435
  Enabled: true
436
+
65
437
  Lint/EnsureReturn:
66
438
  Description: Do not use return in an ensure block.
67
439
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-return-ensure
68
440
  Enabled: true
441
+
442
+ Lint/FloatOutOfRange:
443
+ Description: Catches floating-point literals too large or small for Ruby to represent.
444
+ Enabled: true
445
+
69
446
  Lint/FormatParameterMismatch:
70
447
  Description: The number of parameters to format/sprint must match the fields.
71
448
  Enabled: true
449
+
72
450
  Lint/HandleExceptions:
73
451
  Description: Don't suppress exception.
74
452
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#dont-hide-exceptions
75
453
  Enabled: true
76
- Lint/InvalidCharacterLiteral:
77
- Description: Checks for invalid character literals with a non-escaped whitespace
78
- character.
454
+
455
+ Lint/ImplicitStringConcatenation:
456
+ Description: Checks for adjacent string literals on the same line, which could better be represented as a single string literal.
457
+ Enabled: true
458
+
459
+ Lint/IneffectiveAccessModifier:
460
+ Description: Checks for attempts to use `private` or `protected` to set the visibility of a class method, which does not work.
79
461
  Enabled: true
80
- Lint/LiteralInCondition:
462
+
463
+ Lint/InheritException:
464
+ Description: Avoid inheriting from the `Exception` class.
465
+ Enabled: true
466
+
467
+ Lint/InterpolationCheck:
468
+ Description: Raise warning for interpolation in single q strs
469
+ Enabled: true
470
+
471
+ Lint/LiteralAsCondition:
81
472
  Description: Checks of literals used in conditions.
82
473
  Enabled: true
474
+
83
475
  Lint/LiteralInInterpolation:
84
476
  Description: Checks for literals used in interpolation.
85
477
  Enabled: true
478
+
86
479
  Lint/Loop:
87
- Description: Use Kernel#loop with break rather than begin/end/until or begin/end/while
88
- for post-loop tests.
480
+ Description: Use Kernel#loop with break rather than begin/end/until or begin/end/while for post-loop tests.
89
481
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#loop-with-break
90
482
  Enabled: true
483
+
484
+ Lint/MultipleCompare:
485
+ Description: Use `&&` operator to compare multiple value.
486
+ Enabled: true
487
+
91
488
  Lint/NestedMethodDefinition:
92
489
  Description: Do not use nested method definitions.
93
490
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-nested-methods
94
491
  Enabled: true
492
+
493
+ Lint/NextWithoutAccumulator:
494
+ Description: Do not omit the accumulator when calling `next` in a `reduce`/`inject` block.
495
+ Enabled: true
496
+
95
497
  Lint/NonLocalExitFromIterator:
96
498
  Description: Do not use return in iterator to cause non-local exit.
97
499
  Enabled: true
500
+
98
501
  Lint/ParenthesesAsGroupedExpression:
99
502
  Description: Checks for method calls with a space before the opening parenthesis.
100
503
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#parens-no-spaces
101
504
  Enabled: true
505
+
506
+ Lint/PercentStringArray:
507
+ Description: Checks for unwanted commas and quotes in %w/%W literals.
508
+ Enabled: true
509
+
510
+ Lint/PercentSymbolArray:
511
+ Description: Checks for unwanted commas and colons in %i/%I literals.
512
+ Enabled: true
513
+
514
+ Lint/RandOne:
515
+ Description: Checks for `rand(1)` calls. Such calls always return `0` and most likely a mistake.
516
+ Enabled: true
517
+
518
+ Lint/RedundantWithIndex:
519
+ Description: Checks for redundant `with_index`.
520
+ Enabled: true
521
+
522
+ Lint/RedundantWithObject:
523
+ Description: Checks for redundant `with_object`.
524
+ Enabled: true
525
+
526
+ Lint/RegexpAsCondition:
527
+ Description: Do not use regexp literal as a condition. The regexp literal matches `$_` implicitly.
528
+ Enabled: true
529
+
102
530
  Lint/RequireParentheses:
103
531
  Description: Use parentheses in the method call to avoid confusion about precedence.
104
532
  Enabled: true
533
+
105
534
  Lint/RescueException:
106
535
  Description: Avoid rescuing the Exception class.
107
536
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-blind-rescues
108
537
  Enabled: true
538
+
539
+ Lint/RescueType:
540
+ Description: Avoid rescuing from non constants that could result in a `TypeError`.
541
+ Enabled: true
542
+
543
+ Style/RescueStandardError:
544
+ Description: Avoid rescuing without specifying an error class.
545
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-blind-rescues'
546
+ Enabled: true
547
+
548
+ Lint/SafeNavigationChain:
549
+ Description: Do not chain ordinary method call after safe navigation operator.
550
+ Enabled: true
551
+
552
+ Lint/ScriptPermission:
553
+ Description: Grant script file execute permission.
554
+ Enabled: true
555
+
556
+ Lint/ShadowedException:
557
+ Description: Avoid rescuing a higher level exception before a lower level exception.
558
+ Enabled: true
559
+
109
560
  Lint/ShadowingOuterLocalVariable:
110
- Description: Do not use the same name as outer local variable for block arguments
111
- or block local variables.
561
+ Description: Do not use the same name as outer local variable for block arguments or block local variables.
112
562
  Enabled: true
563
+
113
564
  Lint/StringConversionInInterpolation:
114
565
  Description: Checks for Object#to_s usage in string interpolation.
115
566
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-to-s
116
567
  Enabled: true
568
+
569
+ Lint/Syntax:
570
+ Description: Checks syntax error
571
+ Enabled: true
572
+
117
573
  Lint/UnderscorePrefixedVariableName:
118
574
  Description: Do not use prefix `_` for a variable that is used.
119
575
  Enabled: true
576
+
577
+ Lint/UnifiedInteger:
578
+ Description: Use Integer instead of Fixnum or Bignum
579
+ Enabled: true
580
+
120
581
  Lint/UnneededDisable:
121
- Description: 'Checks for rubocop:disable comments that can be removed. Note: this
122
- cop is not disabled when disabling all cops. It must be explicitly disabled.'
582
+ Description: "Checks for rubocop:disable comments that can be removed. Note: this cop is not disabled when disabling all cops. It must be explicitly disabled."
583
+ Enabled: true
584
+
585
+ Lint/UnneededRequireStatement:
586
+ Description: Checks for unnecessary `require` statement.
123
587
  Enabled: true
588
+
589
+ Lint/UnneededSplatExpansion:
590
+ Description: Checks for splat unnecessarily being called on literals
591
+ Enabled: true
592
+
124
593
  Lint/UnusedBlockArgument:
125
594
  Description: Checks for unused block arguments.
126
595
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#underscore-unused-vars
127
596
  Enabled: true
597
+
128
598
  Lint/UnusedMethodArgument:
129
599
  Description: Checks for unused method arguments.
130
600
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#underscore-unused-vars
131
601
  Enabled: true
602
+
132
603
  Lint/UnreachableCode:
133
604
  Description: Unreachable code.
134
605
  Enabled: true
606
+
607
+ Lint/UriEscapeUnescape:
608
+ Description: "`URI.escape` method is obsolete and should not be used. Instead, use `CGI.escape`, `URI.encode_www_form` or `URI.encode_www_form_component` depending on your specific use case. Also `URI.unescape` method is obsolete and should not be used. Instead, use `CGI.unescape`, `URI.decode_www_form` or `URI.decode_www_form_component` depending on your specific use case."
609
+ Enabled: true
610
+
611
+ Lint/UriRegexp:
612
+ Description: Use `URI::DEFAULT_PARSER.make_regexp` instead of `URI.regexp`.
613
+ Enabled: true
614
+
135
615
  Lint/UselessAccessModifier:
136
616
  Description: Checks for useless access modifiers.
137
617
  Enabled: true
618
+ ContextCreatingMethods: []
619
+ MethodCreatingMethods: []
620
+
138
621
  Lint/UselessAssignment:
139
622
  Description: Checks for useless assignment to a local variable.
140
623
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#underscore-unused-vars
141
624
  Enabled: true
625
+
142
626
  Lint/UselessComparison:
143
627
  Description: Checks for comparison of something with itself.
144
628
  Enabled: true
629
+
145
630
  Lint/UselessElseWithoutRescue:
146
631
  Description: Checks for useless `else` in `begin..end` without `rescue`.
147
632
  Enabled: true
633
+
634
+ Lint/ReturnInVoidContext:
635
+ Description: Checks for return in void context.
636
+ Enabled: true
637
+
148
638
  Lint/UselessSetterCall:
149
639
  Description: Checks for useless setter call to a local variable.
150
640
  Enabled: true
641
+
151
642
  Lint/Void:
152
643
  Description: Possible use of operator/literal/variable in void context.
153
644
  Enabled: true
645
+
646
+ # Department Metrics
154
647
  Metrics/AbcSize:
155
- Description: A calculated magnitude based on number of assignments, branches, and
156
- conditions.
648
+ Description: A calculated magnitude based on number of assignments, branches, and conditions.
157
649
  Reference: http://c2.com/cgi/wiki?AbcMetric
158
650
  Enabled: true
159
- Max: 15
651
+ Max: 20
652
+
653
+ Metrics/BlockLength:
654
+ Description: Avoid long blocks with many lines.
655
+ Enabled: true
160
656
  Exclude:
161
- - test/lib/install_generator_test.rb
162
- - lib/generators/devise_materialize/install_generator.rb
657
+ - Rakefile
658
+ - "**/*.rake"
659
+ - spec/**/*.rb
660
+
163
661
  Metrics/BlockNesting:
164
662
  Description: Avoid excessive block nesting
165
663
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#three-is-the-number-thou-shalt-count
166
664
  Enabled: true
167
665
  Max: 4
666
+
168
667
  Metrics/ClassLength:
169
668
  Description: Avoid classes longer than 100 lines of code.
170
669
  Enabled: true
171
670
  Max: 100
671
+
172
672
  Metrics/CyclomaticComplexity:
173
- Description: A complexity metric that is strongly correlated to the number of test
174
- cases needed to validate a method.
673
+ Description: A complexity metric that is strongly correlated to the number of test cases needed to validate a method.
175
674
  Enabled: true
675
+
176
676
  Metrics/LineLength:
177
677
  Description: Limit lines to 80 characters.
178
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#80-character-limits
678
+ StyleGuide: '#80-character-limits'
179
679
  Enabled: true
680
+
180
681
  Metrics/MethodLength:
181
682
  Description: Avoid methods longer than 10 lines of code.
182
683
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#short-methods
183
684
  Enabled: true
184
- Max: 10
185
685
  Exclude:
186
686
  - test/lib/install_generator_test.rb
687
+ Max: 10
688
+
187
689
  Metrics/ModuleLength:
188
690
  Description: Avoid modules longer than 100 lines of code.
189
691
  Enabled: true
190
692
  Max: 100
693
+
191
694
  Metrics/ParameterLists:
192
695
  Description: Avoid parameter lists longer than three or four parameters.
193
696
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#too-many-params
194
697
  Enabled: false
698
+
195
699
  Metrics/PerceivedComplexity:
196
- Description: A complexity metric geared towards measuring complexity for a human
197
- reader.
700
+ Description: A complexity metric geared towards measuring complexity for a human reader.
198
701
  Enabled: true
199
- Metrics/BlockLength:
200
- Exclude:
201
- - Rakefile
202
- - "**/*.rake"
203
- - spec/**/*.rb
702
+
703
+ # Department Naming
704
+ Naming/AccessorMethodName:
705
+ Description: Check the naming of accessor methods for get_/set_.
706
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#accessor_mutator_method_names
707
+ Enabled: false
708
+
709
+ Naming/AsciiIdentifiers:
710
+ Description: Use only ascii symbols in identifiers.
711
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#english-identifiers
712
+ Enabled: false
713
+
714
+ Naming/ClassAndModuleCamelCase:
715
+ Description: Use CamelCase for classes and modules.
716
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#camelcase-classes
717
+ Enabled: true
718
+
719
+ Naming/ConstantName:
720
+ Description: Constants should use SCREAMING_SNAKE_CASE.
721
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#screaming-snake-case
722
+ Enabled: true
723
+
724
+ Naming/FileName:
725
+ Description: Use snake_case for source file names.
726
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#snake-case-files
727
+ Enabled: true
728
+
729
+ Naming/HeredocDelimiterCase:
730
+ Description: Use configured case for heredoc delimiters.
731
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#heredoc-delimiters
732
+ Enabled: true
733
+
734
+ Naming/HeredocDelimiterNaming:
735
+ Description: Use descriptive heredoc delimiters.
736
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#heredoc-delimiters
737
+ Enabled: true
738
+
739
+ Naming/MethodName:
740
+ Description: Use the configured style when naming methods.
741
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#snake-case-symbols-methods-vars
742
+ Enabled: false
743
+
744
+ Naming/PredicateName:
745
+ Description: Check the names of predicate methods.
746
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#bool-methods-qmark
747
+ Enabled: true
748
+
749
+ Naming/BinaryOperatorParameterName:
750
+ Description: When defining binary operators, name the argument other.
751
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#other-arg
752
+ Enabled: true
753
+
754
+ Naming/VariableName:
755
+ Description: Use the configured style when naming variables.
756
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#snake-case-symbols-methods-vars
757
+ Enabled: true
758
+
759
+ Naming/VariableNumber:
760
+ Description: Use the configured style when numbering variables.
761
+ Enabled: true
762
+
763
+ # Department Performance
764
+ Performance/Caller:
765
+ Description: Use `caller(n..n)` instead of `caller`.
766
+ Enabled: true
767
+
768
+ Performance/Casecmp:
769
+ Description: Use `casecmp` rather than `downcase ==`, `upcase ==`, `== downcase`, or `== upcase`..
770
+ Reference: https://github.com/JuanitoFatas/fast-ruby#stringcasecmp-vs-stringdowncase---code
771
+ Enabled: true
772
+
773
+ Performance/CaseWhenSplat:
774
+ Description: Place `when` conditions that use splat at the end of the list of `when` branches.
775
+ Enabled: true
776
+
204
777
  Performance/Count:
205
- Description: Use `count` instead of `select...size`, `reject...size`, `select...count`,
206
- `reject...count`, `select...length`, and `reject...length`.
778
+ Description: Use `count` instead of `select...size`, `reject...size`, `select...count`, `reject...count`, `select...length`, and `reject...length`.
779
+ SafeMode: true
207
780
  Enabled: true
781
+
208
782
  Performance/Detect:
209
- Description: Use `detect` instead of `select.first`, `find_all.first`, `select.last`,
210
- and `find_all.last`.
211
- Reference: https://github.com/JuanitoFatas/fast-ruby#enumerabledetect-vs-enumerableselectfirst-code
783
+ Description: Use `detect` instead of `select.first`, `find_all.first`, `select.last`, and `find_all.last`.
784
+ Reference: 'https://github.com/JuanitoFatas/fast-ruby#enumerabledetect-vs-enumerableselectfirst-code'
785
+ SafeMode: true
786
+ Enabled: true
787
+
788
+ Performance/DoubleStartEndWith:
789
+ Description: Use `str.{start,end}_with?(x, ..., y, ...)` instead of `str.{start,end}_with?(x, ...) || str.{start,end}_with?(y, ...)`.
790
+ Enabled: true
791
+
792
+ Performance/EndWith:
793
+ Description: Use `end_with?` instead of a regex match anchored to the end of a string.
794
+ Reference: https://github.com/JuanitoFatas/fast-ruby#stringmatch-vs-stringstart_withstringend_with-code-start-code-end
795
+ AutoCorrect: false
212
796
  Enabled: true
797
+
798
+ Performance/FixedSize:
799
+ Description: Do not compute the size of statically sized objects except in constants
800
+ Enabled: true
801
+
213
802
  Performance/FlatMap:
214
- Description: Use `Enumerable#flat_map` instead of `Enumerable#map...Array#flatten(1)`
215
- or `Enumberable#collect..Array#flatten(1)`
803
+ Description: Use `Enumerable#flat_map` instead of `Enumerable#map...Array#flatten(1)` or `Enumberable#collect..Array#flatten(1)`
216
804
  Reference: https://github.com/JuanitoFatas/fast-ruby#enumerablemaparrayflatten-vs-enumerableflat_map-code
217
805
  Enabled: true
218
806
  EnabledForFlattenWithoutParams: false
807
+
808
+ Performance/HashEachMethods:
809
+ Description: Use `Hash#each_key` and `Hash#each_value` instead of `Hash#keys.each` and `Hash#values.each`.
810
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#hash-each
811
+ Enabled: true
812
+ AutoCorrect: false
813
+
814
+ Performance/LstripRstrip:
815
+ Description: Use `strip` instead of `lstrip.rstrip`.
816
+ Enabled: true
817
+
818
+ Performance/RangeInclude:
819
+ Description: Use `Range#cover?` instead of `Range#include?`.
820
+ Reference: https://github.com/JuanitoFatas/fast-ruby#cover-vs-include-code
821
+ Enabled: true
822
+
823
+ Performance/RedundantBlockCall:
824
+ Description: Use `yield` instead of `block.call`.
825
+ Reference: https://github.com/JuanitoFatas/fast-ruby#proccall-vs-yield-code
826
+ Enabled: true
827
+
828
+ Performance/RedundantMatch:
829
+ Description: Use `=~` instead of `String#match` or `Regexp#match` in a context where the returned `MatchData` is not needed.
830
+ Enabled: true
831
+
832
+ Performance/RedundantMerge:
833
+ Description: Use Hash#[]=, rather than Hash#merge! with a single key-value pair.
834
+ Reference: https://github.com/JuanitoFatas/fast-ruby#hashmerge-vs-hash-code
835
+ Enabled: true
836
+
837
+ Performance/RedundantSortBy:
838
+ Description: Use `sort` instead of `sort_by { |x| x }`.
839
+ Enabled: true
840
+
841
+ Performance/RegexpMatch:
842
+ Description: Use `match?` instead of `Regexp#match`, `String#match`, `Symbol#match`, `Regexp#===`, or `=~` when `MatchData` is not used.
843
+ Enabled: true
844
+
219
845
  Performance/ReverseEach:
220
846
  Description: Use `reverse_each` instead of `reverse.each`.
221
847
  Reference: https://github.com/JuanitoFatas/fast-ruby#enumerablereverseeach-vs-enumerablereverse_each-code
222
848
  Enabled: true
849
+
223
850
  Performance/Sample:
224
- Description: Use `sample` instead of `shuffle.first`, `shuffle.last`, and `shuffle[Fixnum]`.
851
+ Description: Use `sample` instead of `shuffle.first`, `shuffle.last`, and `shuffle[Integer]`.
225
852
  Reference: https://github.com/JuanitoFatas/fast-ruby#arrayshufflefirst-vs-arraysample-code
226
853
  Enabled: true
854
+
227
855
  Performance/Size:
228
- Description: Use `size` instead of `count` for counting the number of elements in
229
- `Array` and `Hash`.
856
+ Description: Use `size` instead of `count` for counting the number of elements in `Array` and `Hash`.
230
857
  Reference: https://github.com/JuanitoFatas/fast-ruby#arraycount-vs-arraysize-code
231
858
  Enabled: true
859
+
860
+ Performance/CompareWithBlock:
861
+ Description: Use `sort_by(&:foo)` instead of `sort { |a, b| a.foo <=> b.foo }`.
862
+ Enabled: true
863
+
864
+ Performance/StartWith:
865
+ Description: Use `start_with?` instead of a regex match anchored to the beginning of a string.
866
+ Reference: https://github.com/JuanitoFatas/fast-ruby#stringmatch-vs-stringstart_withstringend_with-code-start-code-end
867
+ AutoCorrect: false
868
+ Enabled: true
869
+
232
870
  Performance/StringReplacement:
233
- Description: Use `tr` instead of `gsub` when you are replacing the same number of
234
- characters. Use `delete` instead of `gsub` when you are deleting characters.
871
+ Description: Use `tr` instead of `gsub` when you are replacing the same number of characters. Use `delete` instead of `gsub` when you are deleting characters.
235
872
  Reference: https://github.com/JuanitoFatas/fast-ruby#stringgsub-vs-stringtr-code
236
873
  Enabled: true
874
+
875
+ Performance/TimesMap:
876
+ Description: Checks for .times.map calls.
877
+ AutoCorrect: false
878
+ Enabled: true
879
+
880
+ Performance/UnfreezeString:
881
+ Description: Use unary plus to get an unfrozen string literal.
882
+ Enabled: true
883
+
884
+ Performance/UriDefaultParser:
885
+ Description: Use `URI::DEFAULT_PARSER` instead of `URI::Parser.new`.
886
+ Enabled: true
887
+
888
+ # Department Rails
237
889
  Rails/ActionFilter:
238
890
  Description: Enforces consistent use of action filter methods.
239
891
  Enabled: false
892
+
893
+ Rails/ApplicationJob:
894
+ Description: Check that jobs subclass ApplicationJob.
895
+ Enabled: true
896
+
897
+ Rails/ApplicationRecord:
898
+ Description: Check that models subclass ApplicationRecord.
899
+ Enabled: true
900
+
901
+ Rails/ActiveSupportAliases:
902
+ Description: "Avoid ActiveSupport aliases of standard ruby methods: `String#starts_with?`, `String#ends_with?`, `Array#append`, `Array#prepend`."
903
+ Enabled: true
904
+
905
+ Rails/Blank:
906
+ Description: Enforce using `blank?` and `present?`.
907
+ Enabled: true
908
+ NilOrEmpty: true
909
+ NotPresent: true
910
+ UnlessPresent: true
911
+
240
912
  Rails/Date:
241
- Description: Checks the correct usage of date aware methods, such as Date.today,
242
- Date.current etc.
913
+ Description: Checks the correct usage of date aware methods, such as Date.today, Date.current etc.
243
914
  Enabled: true
915
+
244
916
  Rails/Delegate:
245
917
  Description: Prefer delegate method for delegations.
246
918
  Enabled: true
919
+
920
+ Rails/DelegateAllowBlank:
921
+ Description: Do not use allow_blank as an option to delegate.
922
+ Enabled: true
923
+
924
+ Rails/DynamicFindBy:
925
+ Description: Use `find_by` instead of dynamic `find_by_*`.
926
+ StyleGuide: https://github.com/bbatsov/rails-style-guide#find_by
927
+ Enabled: true
928
+
929
+ Rails/EnumUniqueness:
930
+ Description: Avoid duplicate integers in hash-syntax `enum` declaration.
931
+ Enabled: true
932
+
933
+ Rails/Exit:
934
+ Description: Favor `fail`, `break`, `return`, etc. over `exit` in application or library code outside of Rake files to avoid exits during unit testing or running in production.
935
+ Enabled: true
936
+
937
+ Rails/FilePath:
938
+ Description: Use `Rails.root.join` for file path joining.
939
+ Enabled: true
940
+
247
941
  Rails/FindBy:
248
942
  Description: Prefer find_by over where.first.
943
+ StyleGuide: https://github.com/bbatsov/rails-style-guide#find_by
249
944
  Enabled: true
945
+
250
946
  Rails/FindEach:
251
947
  Description: Prefer all.find_each over all.find.
948
+ StyleGuide: https://github.com/bbatsov/rails-style-guide#find-each
252
949
  Enabled: true
950
+
253
951
  Rails/HasAndBelongsToMany:
254
952
  Description: Prefer has_many :through to has_and_belongs_to_many.
953
+ StyleGuide: https://github.com/bbatsov/rails-style-guide#has-many-through
954
+ Enabled: true
955
+
956
+ Rails/HasManyOrHasOneDependent:
957
+ Description: Define the dependent option to the has_many and has_one associations.
958
+ StyleGuide: https://github.com/bbatsov/rails-style-guide#has_many-has_one-dependent-option
959
+ Enabled: true
960
+
961
+ Rails/HttpPositionalArguments:
962
+ Description: Use keyword arguments instead of positional arguments in http method calls.
255
963
  Enabled: true
964
+
965
+ Rails/NotNullColumn:
966
+ Description: Do not add a NOT NULL column without a default value
967
+ Enabled: true
968
+
256
969
  Rails/Output:
257
970
  Description: Checks for calls to puts, print, etc.
258
971
  Enabled: true
972
+
973
+ Rails/OutputSafety:
974
+ Description: The use of `html_safe` or `raw` may be a security risk.
975
+ Enabled: true
976
+
977
+ Rails/PluralizationGrammar:
978
+ Description: Checks for incorrect grammar when using methods like `3.day.ago`.
979
+ Enabled: true
980
+
981
+ Rails/Present:
982
+ Description: Enforce using `blank?` and `present?`.
983
+ Enabled: true
984
+ NotNilAndNotEmpty: true
985
+ NotBlank: true
986
+ UnlessBlank: true
987
+
259
988
  Rails/ReadWriteAttribute:
260
989
  Description: Checks for read_attribute(:attr) and write_attribute(:attr, val).
990
+ StyleGuide: https://github.com/bbatsov/rails-style-guide#read-attribute
261
991
  Enabled: false
992
+
993
+ Rails/RelativeDateConstant:
994
+ Description: Do not assign relative date to constants.
995
+ Enabled: true
996
+
997
+ Rails/RequestReferer:
998
+ Description: Use consistent syntax for request.referer.
999
+ Enabled: true
1000
+
1001
+ Rails/ReversibleMigration:
1002
+ Description: Checks whether the change method of the migration file is reversible.
1003
+ StyleGuide: https://github.com/bbatsov/rails-style-guide#reversible-migration
1004
+ Reference: http://api.rubyonrails.org/classes/ActiveRecord/Migration/CommandRecorder.html
1005
+ Enabled: true
1006
+
1007
+ Rails/SafeNavigation:
1008
+ Description: Use Ruby's safe navigation operator (`&.`) instead of `try!`
1009
+ Enabled: true
1010
+
1011
+ Rails/SaveBang:
1012
+ Description: Identifies possible cases where Active Record save! or related should be used.
1013
+ StyleGuide: https://github.com/bbatsov/rails-style-guide#save-bang
1014
+ Enabled: false
1015
+
262
1016
  Rails/ScopeArgs:
263
1017
  Description: Checks the arguments of ActiveRecord scopes.
264
1018
  Enabled: true
1019
+
265
1020
  Rails/TimeZone:
266
1021
  Description: Checks the correct usage of time zone aware methods.
267
1022
  StyleGuide: https://github.com/bbatsov/rails-style-guide#time
268
1023
  Reference: http://danilenko.org/2012/7/6/rails_timezones
269
1024
  Enabled: true
1025
+
1026
+ Rails/UniqBeforePluck:
1027
+ Description: Prefer the use of uniq or distinct before pluck.
1028
+ Enabled: true
1029
+
1030
+ Rails/UnknownEnv:
1031
+ Description: Use correct environment name.
1032
+ Enabled: true
1033
+
1034
+ Rails/SkipsModelValidations:
1035
+ Description: Use methods that skips model validations with caution. See reference for more information.
1036
+ Reference: http://guides.rubyonrails.org/active_record_validations.html#skipping-validations
1037
+ Enabled: true
1038
+
270
1039
  Rails/Validation:
271
1040
  Description: Use validates :attribute, hash of validations.
272
1041
  Enabled: true
273
- Style/AccessModifierIndentation:
274
- Description: Check indentation of private/protected visibility modifiers.
275
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#indent-public-private-protected
276
- Enabled: false
277
- Style/AccessorMethodName:
278
- Description: Check the naming of accessor methods for get_/set_.
279
- Enabled: false
280
- Style/Alias:
281
- Description: Use alias_method instead of alias.
282
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#alias-method
283
- Enabled: false
284
- Style/AlignArray:
285
- Description: Align the elements of an array literal if they span more than one line.
286
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#align-multiline-arrays
1042
+
1043
+ # Department Security
1044
+ Security/Eval:
1045
+ Description: The use of eval represents a serious security risk.
287
1046
  Enabled: true
288
- Style/AlignHash:
289
- Description: Align the elements of a hash literal if they span more than one line.
1047
+
1048
+ Security/JSONLoad:
1049
+ Description: Prefer usage of `JSON.parse` over `JSON.load` due to potential security issues. See reference for more information.
1050
+ Reference: http://ruby-doc.org/stdlib-2.3.0/libdoc/json/rdoc/JSON.html#method-i-load
290
1051
  Enabled: true
291
- Style/AlignParameters:
292
- Description: Align the parameters of a method call if they span more than one line.
293
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-double-indent
1052
+ AutoCorrect: false
1053
+
1054
+ Security/MarshalLoad:
1055
+ Description: Avoid using of `Marshal.load` or `Marshal.restore` due to potential security issues. See reference for more information.
1056
+ Reference: http://ruby-doc.org/core-2.3.3/Marshal.html#module-Marshal-label-Security+considerations
1057
+ Enabled: true
1058
+
1059
+ Security/YAMLLoad:
1060
+ Description: Prefer usage of `YAML.safe_load` over `YAML.load` due to potential security issues. See reference for more information.
1061
+ Reference: https://ruby-doc.org/stdlib-2.3.3/libdoc/yaml/rdoc/YAML.html#module-YAML-label-Security
294
1062
  Enabled: true
1063
+
1064
+ # Department Style
1065
+ Style/Alias:
1066
+ Description: Use alias instead of alias_method.
1067
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#alias-method
1068
+ Enabled: false
1069
+
295
1070
  Style/AndOr:
296
1071
  Description: Use &&/|| instead of and/or.
297
1072
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-and-or-or
298
1073
  Enabled: true
1074
+
299
1075
  Style/ArrayJoin:
300
1076
  Description: Use Array#join instead of Array#*.
301
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#array-join
1077
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#array-join'
302
1078
  Enabled: false
1079
+
303
1080
  Style/AsciiComments:
304
1081
  Description: Use only ascii symbols in comments.
305
1082
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#english-comments
306
1083
  Enabled: false
307
- Style/AsciiIdentifiers:
308
- Description: Use only ascii symbols in identifiers.
309
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#english-identifiers
310
- Enabled: false
1084
+
311
1085
  Style/Attr:
312
1086
  Description: Checks for uses of Module#attr.
313
1087
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#attr
314
1088
  Enabled: true
1089
+
1090
+ Style/AutoResourceCleanup:
1091
+ Description: Suggests the usage of an auto resource cleanup version of a method (if available).
1092
+ Enabled: false
1093
+
315
1094
  Style/BeginBlock:
316
1095
  Description: Avoid the use of BEGIN blocks.
317
1096
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-BEGIN-blocks
318
1097
  Enabled: true
1098
+
319
1099
  Style/BarePercentLiterals:
320
1100
  Description: Checks if usage of %() or %Q() matches configuration.
321
1101
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#percent-q-shorthand
322
1102
  Enabled: true
1103
+
323
1104
  Style/BlockComments:
324
1105
  Description: Do not use block comments.
325
1106
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-block-comments
326
1107
  Enabled: false
327
- Style/BlockEndNewline:
328
- Description: Put end statement of multiline block on its own line.
329
- Enabled: true
1108
+
330
1109
  Style/BlockDelimiters:
331
- Description: Avoid using {...} for multi-line blocks (multiline chaining is always
332
- ugly). Prefer {...} over do...end for single-line blocks.
1110
+ Description: Avoid using {...} for multi-line blocks (multiline chaining is always ugly). Prefer {...} over do...end for single-line blocks.
333
1111
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#single-line-blocks
334
1112
  Enabled: true
1113
+
335
1114
  Style/BracesAroundHashParameters:
336
1115
  Description: Enforce braces style around hash parameters.
337
1116
  Enabled: false
1117
+
338
1118
  Style/CaseEquality:
339
1119
  Description: Avoid explicit use of the case equality operator(===).
340
1120
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-case-equality
341
1121
  Enabled: false
342
- Style/CaseIndentation:
343
- Description: Indentation of when in a case/when/[else/]end.
344
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#indent-when-to-case
345
- Enabled: true
1122
+
346
1123
  Style/CharacterLiteral:
347
1124
  Description: Checks for uses of character literals.
348
1125
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-character-literals
349
1126
  Enabled: false
350
- Style/ClassAndModuleCamelCase:
351
- Description: Use CamelCase for classes and modules.
352
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#camelcase-classes
353
- Enabled: true
1127
+
354
1128
  Style/ClassAndModuleChildren:
355
1129
  Description: Checks style of children classes and modules.
1130
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#namespace-definition
356
1131
  Enabled: false
1132
+
357
1133
  Style/ClassCheck:
358
1134
  Description: Enforces consistent use of `Object#is_a?` or `Object#kind_of?`.
359
1135
  Enabled: true
1136
+
360
1137
  Style/ClassMethods:
361
1138
  Description: Use self when defining module/class methods.
362
1139
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#def-self-class-methods
363
1140
  Enabled: false
1141
+
364
1142
  Style/ClassVars:
365
1143
  Description: Avoid the use of class variables.
366
1144
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-class-vars
367
1145
  Enabled: false
368
- Style/ClosingParenthesisIndentation:
369
- Description: Checks the indentation of hanging closing parentheses.
1146
+
1147
+ Style/CollectionMethods:
1148
+ Description: Preferred collection methods.
1149
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#map-find-select-reduce-size
370
1150
  Enabled: false
1151
+
371
1152
  Style/ColonMethodCall:
372
1153
  Description: 'Do not use :: for method call.'
373
1154
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#double-colons
374
1155
  Enabled: true
1156
+
375
1157
  Style/CommandLiteral:
376
1158
  Description: Use `` or %x around command literals.
377
1159
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#percent-x
378
1160
  Enabled: false
1161
+
379
1162
  Style/CommentAnnotation:
380
- Description: Checks formatting of annotation comments.
1163
+ Description: Checks formatting of special comments (TODO, FIXME, OPTIMIZE, HACK, REVIEW).
381
1164
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#annotate-keywords
382
1165
  Enabled: false
383
- Style/CommentIndentation:
384
- Description: Indentation of comments.
1166
+
1167
+ Style/CommentedKeyword:
1168
+ Description: Do not place comments on the same line as certain keywords.
385
1169
  Enabled: false
386
- Style/ConstantName:
387
- Description: Constants should use SCREAMING_SNAKE_CASE.
388
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#screaming-snake-case
1170
+
1171
+ Style/ConditionalAssignment:
1172
+ Description: Use the return value of `if` and `case` statements for assignment to a variable and variable comparison instead of assigning that variable inside of each branch.
389
1173
  Enabled: true
1174
+
1175
+ Style/Copyright:
1176
+ Description: Include a copyright notice in each file before any code.
1177
+ Enabled: false
1178
+
1179
+ Style/DateTime:
1180
+ Description: Use Date or Time over DateTime.
1181
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#date--time
1182
+ Enabled: false
1183
+
390
1184
  Style/DefWithParentheses:
391
1185
  Description: Use def with parentheses when there are arguments.
392
1186
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#method-parens
393
1187
  Enabled: true
1188
+
1189
+ Style/Dir:
1190
+ Description: Use the `__dir__` method to retrieve the canonicalized absolute path to the current file.
1191
+ Enabled: true
1192
+
394
1193
  Style/Documentation:
395
1194
  Description: Document classes and non-namespace modules.
396
1195
  Enabled: false
397
- Style/DotPosition:
398
- Description: Checks the position of the dot in multi-line method calls.
399
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#consistent-multi-line-chains
400
- Enabled: true
1196
+ Exclude:
1197
+ - 'spec/**/*'
1198
+ - 'test/**/*'
1199
+
1200
+ Style/DocumentationMethod:
1201
+ Description: Public methods.
1202
+ Enabled: false
1203
+ Exclude:
1204
+ - 'spec/**/*'
1205
+ - 'test/**/*'
1206
+
401
1207
  Style/DoubleNegation:
402
1208
  Description: Checks for uses of double negation (!!).
403
1209
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-bang-bang
404
1210
  Enabled: true
1211
+
1212
+ Style/EachForSimpleLoop:
1213
+ Description: Use `Integer#times` for a simple loop which iterates a fixed number of times.
1214
+ Enabled: true
1215
+
405
1216
  Style/EachWithObject:
406
1217
  Description: Prefer `each_with_object` over `inject` or `reduce`.
407
1218
  Enabled: false
408
- Style/ElseAlignment:
409
- Description: Align elses and elsifs correctly.
410
- Enabled: true
1219
+
411
1220
  Style/EmptyElse:
412
1221
  Description: Avoid empty else-clauses.
413
1222
  Enabled: true
414
- Style/EmptyLineBetweenDefs:
415
- Description: Use empty lines between defs.
416
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#empty-lines-between-methods
417
- Enabled: true
418
- Style/EmptyLines:
419
- Description: Don't use several empty lines in a row.
1223
+
1224
+ Style/EmptyCaseCondition:
1225
+ Description: Avoid empty condition in case statements.
420
1226
  Enabled: true
421
- Style/EmptyLinesAroundAccessModifier:
422
- Description: Keep blank lines around access modifiers.
423
- Enabled: false
424
- Style/EmptyLinesAroundBlockBody:
425
- Description: Keeps track of empty lines around block bodies.
426
- Enabled: false
427
- Style/EmptyLinesAroundClassBody:
428
- Description: Keeps track of empty lines around class bodies.
429
- Enabled: false
430
- Style/EmptyLinesAroundModuleBody:
431
- Description: Keeps track of empty lines around module bodies.
432
- Enabled: false
433
- Style/EmptyLinesAroundMethodBody:
434
- Description: Keeps track of empty lines around method bodies.
435
- Enabled: false
1227
+
436
1228
  Style/EmptyLiteral:
437
1229
  Description: Prefer literals to Array.new/Hash.new/String.new.
438
1230
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#literal-array-hash
439
1231
  Enabled: false
1232
+
1233
+ Style/EmptyMethod:
1234
+ Description: Checks the formatting of empty method definitions.
1235
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-single-line-methods
1236
+ Enabled: false
1237
+
440
1238
  Style/EndBlock:
441
1239
  Description: Avoid the use of END blocks.
442
1240
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-END-blocks
443
1241
  Enabled: false
444
- Style/EndOfLine:
445
- Description: Use Unix-style line endings.
446
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#crlf
447
- Enabled: false
1242
+
1243
+ Style/Encoding:
1244
+ Description: Use UTF-8 as the source file encoding.
1245
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#utf-8
1246
+ Enabled: true
1247
+
448
1248
  Style/EvenOdd:
449
- Description: Favor the use of Fixnum#even? && Fixnum#odd?
1249
+ Description: Favor the use of Integer#even? && Integer#odd?
450
1250
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#predicate-methods
451
1251
  Enabled: true
452
- Style/ExtraSpacing:
453
- Description: Do not use unnecessary spacing.
454
- Enabled: true
455
- Style/FileName:
456
- Description: Use snake_case for source file names.
457
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#snake-case-files
1252
+
1253
+ Style/FrozenStringLiteralComment:
1254
+ Description: Add the frozen_string_literal comment to the top of files to help transition from Ruby 2.3.0 to Ruby 3.0.
458
1255
  Enabled: true
459
- Style/InitialIndentation:
460
- Description: Checks the indentation of the first non-blank non-comment line in a
461
- file.
462
- Enabled: false
463
- Style/FirstParameterIndentation:
464
- Description: Checks the indentation of the first parameter in a method call.
465
- Enabled: false
1256
+
466
1257
  Style/FlipFlop:
467
1258
  Description: Checks for flip flops
468
1259
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-flip-flops
469
1260
  Enabled: true
1261
+
470
1262
  Style/For:
471
1263
  Description: Checks use of for or each in multiline loops.
472
1264
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-for-loops
473
1265
  Enabled: true
1266
+
474
1267
  Style/FormatString:
475
1268
  Description: Enforce the use of Kernel#sprintf, Kernel#format or String#%.
476
1269
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#sprintf
477
1270
  Enabled: false
1271
+
1272
+ Style/FormatStringToken:
1273
+ Description: Use a consistent style for format string tokens.
1274
+ Enabled: true
1275
+
478
1276
  Style/GlobalVars:
479
1277
  Description: Do not introduce global variables.
480
1278
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#instance-vars
481
1279
  Reference: http://www.zenspider.com/Languages/Ruby/QuickRef.html
482
1280
  Enabled: true
1281
+
483
1282
  Style/GuardClause:
484
1283
  Description: Check for conditionals that can be replaced with guard clauses
485
1284
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-nested-conditionals
486
1285
  Enabled: true
1286
+
487
1287
  Style/HashSyntax:
488
- Description: 'Prefer Ruby 1.9 hash syntax { a: 1, b: 2 } over 1.8 syntax { :a =>
489
- 1, :b => 2 }.'
1288
+ Description: 'Prefer Ruby 1.9 hash syntax { a: 1, b: 2 } over 1.8 syntax { :a => 1, :b => 2 }.'
490
1289
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#hash-literals
491
1290
  Enabled: true
1291
+
1292
+ Style/IfInsideElse:
1293
+ Description: Finds if nodes inside else, which can be converted to elsif.
1294
+ Enabled: true
1295
+
492
1296
  Style/IfUnlessModifier:
493
1297
  Description: Favor modifier if/unless usage when you have a single-line body.
494
1298
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#if-as-a-modifier
495
1299
  Enabled: true
1300
+
1301
+ Style/IfUnlessModifierOfIfUnless:
1302
+ Description: Avoid modifier if/unless usage on conditionals.
1303
+ Enabled: true
1304
+
496
1305
  Style/IfWithSemicolon:
497
1306
  Description: Do not use if x; .... Use the ternary operator instead.
498
1307
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-semicolon-ifs
499
1308
  Enabled: true
500
- Style/IndentationConsistency:
501
- Description: Keep indentation straight.
502
- Enabled: false
503
- Style/IndentationWidth:
504
- Description: Use 2 spaces for indentation.
505
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-indentation
1309
+
1310
+ Style/IdenticalConditionalBranches:
1311
+ Description: Checks that conditional statements do not have an identical line at the end of each branch, which can validly be moved out of the conditional.
506
1312
  Enabled: true
507
- Style/IndentArray:
508
- Description: Checks the indentation of the first element in an array literal.
509
- Enabled: false
510
- Style/IndentHash:
511
- Description: Checks the indentation of the first key in a hash literal.
512
- Enabled: false
1313
+
513
1314
  Style/InfiniteLoop:
514
1315
  Description: Use Kernel#loop for infinite loops.
515
1316
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#infinite-loop
516
1317
  Enabled: true
1318
+
1319
+ Style/InlineComment:
1320
+ Description: Avoid trailing inline comments.
1321
+ Enabled: false
1322
+
1323
+ Style/InverseMethods:
1324
+ Description: Use the inverse method instead of `!.method` if an inverse method is defined.
1325
+ Enabled: true
1326
+
1327
+ Style/ImplicitRuntimeError:
1328
+ Description: Use `raise` or `fail` with an explicit exception class and message, rather than just a message.
1329
+ Enabled: false
1330
+
517
1331
  Style/Lambda:
518
1332
  Description: Use the new lambda literal syntax for single-line blocks.
519
1333
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#lambda-multi-line
520
1334
  Enabled: true
1335
+
521
1336
  Style/LambdaCall:
522
1337
  Description: Use lambda.call(...) instead of lambda.(...).
523
1338
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#proc-call
524
1339
  Enabled: false
525
- Style/LeadingCommentSpace:
526
- Description: Comments should start with a space.
527
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#hash-space
528
- Enabled: true
1340
+
529
1341
  Style/LineEndConcatenation:
530
- Description: Use \ instead of + or << to concatenate two string literals at line
531
- end.
1342
+ Description: Use \ instead of + or << to concatenate two string literals at line end.
532
1343
  Enabled: true
1344
+
533
1345
  Style/MethodCallWithoutArgsParentheses:
534
1346
  Description: Do not use parentheses for method calls with no arguments.
535
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-args-no-parens
1347
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#method-invocation-parens
536
1348
  Enabled: true
1349
+
1350
+ Style/MethodCallWithArgsParentheses:
1351
+ Description: Use parentheses for method calls with arguments.
1352
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#method-invocation-parens
1353
+ Enabled: false
1354
+
1355
+ Style/MethodCalledOnDoEndBlock:
1356
+ Description: Avoid chaining a method call on a do...end block.
1357
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#single-line-blocks
1358
+ Enabled: false
1359
+
537
1360
  Style/MethodDefParentheses:
538
1361
  Description: Checks if the method definitions have or don't have parentheses.
539
1362
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#method-parens
540
1363
  Enabled: true
541
- Style/MethodName:
542
- Description: Use the configured style when naming methods.
543
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#snake-case-symbols-methods-vars
544
- Enabled: false
1364
+
1365
+ Style/MethodMissing:
1366
+ Description: Avoid using `method_missing`.
1367
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-method-missing
1368
+ Enabled: true
1369
+
1370
+ Style/MinMax:
1371
+ Description: Use `Enumerable#minmax` instead of `Enumerable#min` and `Enumerable#max` in conjunction.'
1372
+ Enabled: true
1373
+
1374
+ Style/MissingElse:
1375
+ Description: Require if/case expressions to have an else branches. If enabled, it is recommended that Style/UnlessElse and Style/EmptyElse be enabled. This will conflict with Style/EmptyElse if Style/EmptyElse is configured to style "both"
1376
+ Enabled: false
1377
+ EnforcedStyle: both
1378
+ SupportedStyles:
1379
+ - if
1380
+ - case
1381
+ - both
1382
+
1383
+ Style/MixinGrouping:
1384
+ Description: Checks for grouping of mixins in `class` and `module` bodies.
1385
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#mixin-grouping
1386
+ Enabled: true
1387
+
545
1388
  Style/ModuleFunction:
546
1389
  Description: Checks for usage of `extend self` in modules.
547
1390
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#module-function
548
1391
  Enabled: true
1392
+
549
1393
  Style/MultilineBlockChain:
550
1394
  Description: Avoid multi-line chains of blocks.
551
1395
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#single-line-blocks
552
1396
  Enabled: false
553
- Style/MultilineBlockLayout:
554
- Description: Ensures newlines after multiline block do statements.
555
- Enabled: true
1397
+
556
1398
  Style/MultilineIfThen:
557
1399
  Description: Do not use then for multi-line if/unless.
558
1400
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-then
559
1401
  Enabled: true
560
- Style/MultilineOperationIndentation:
561
- Description: Checks indentation of binary operations that span more than one line.
562
- Enabled: false
1402
+
1403
+ Style/MultilineIfModifier:
1404
+ Description: Only use if/unless modifiers on single line statements.
1405
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-multiline-if-modifiers
1406
+ Enabled: true
1407
+
1408
+ Style/MultilineMemoization:
1409
+ Description: Wrap multiline memoizations in a `begin` and `end` block.
1410
+ Enabled: true
1411
+
563
1412
  Style/MultilineTernaryOperator:
564
1413
  Description: 'Avoid multi-line ?: (the ternary operator); use if/unless instead.'
565
1414
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-multiline-ternary
566
1415
  Enabled: true
1416
+
1417
+ Style/MultipleComparison:
1418
+ Description: Avoid comparing a variable with multiple items in a conditional, use Array#include? instead.
1419
+ Enabled: true
1420
+
1421
+ Style/MutableConstant:
1422
+ Description: Do not assign mutable objects to constants.
1423
+ Enabled: true
1424
+
567
1425
  Style/NegatedIf:
568
1426
  Description: Favor unless over if for negative conditions (or control flow or).
569
1427
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#unless-for-negatives
570
1428
  Enabled: true
1429
+
571
1430
  Style/NegatedWhile:
572
1431
  Description: Favor until over while for negative conditions.
573
1432
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#until-for-negatives
574
1433
  Enabled: true
1434
+
1435
+ Style/NestedModifier:
1436
+ Description: Avoid using nested modifiers.
1437
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-nested-modifiers
1438
+ Enabled: true
1439
+
1440
+ Style/NestedParenthesizedCalls:
1441
+ Description: Parenthesize method calls which are nested inside the argument list of another parenthesized method call.
1442
+ Enabled: true
1443
+
575
1444
  Style/NestedTernaryOperator:
576
1445
  Description: Use one expression per branch in a ternary operator.
577
1446
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-nested-ternary
578
1447
  Enabled: true
1448
+
579
1449
  Style/Next:
580
1450
  Description: Use `next` to skip iteration instead of a condition at the end.
581
1451
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-nested-conditionals
582
1452
  Enabled: true
1453
+
583
1454
  Style/NilComparison:
584
- Description: Prefer x.nil? to x == nil.
585
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#predicate-methods
1455
+ Description: 'Prefer x.nil? to x == nil.'
1456
+ StyleGuide: '#predicate-methods'
586
1457
  Enabled: true
1458
+
587
1459
  Style/NonNilCheck:
588
1460
  Description: Checks for redundant nil checks.
589
1461
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-non-nil-checks
590
1462
  Enabled: true
1463
+
591
1464
  Style/Not:
592
1465
  Description: Use ! instead of not.
593
1466
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#bang-not-not
594
1467
  Enabled: true
1468
+
595
1469
  Style/NumericLiterals:
596
1470
  Description: Add underscores to large numeric literals to improve their readability.
597
1471
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#underscores-in-numerics
598
1472
  Enabled: true
1473
+
1474
+ Style/NumericLiteralPrefix:
1475
+ Description: Use smallcase prefixes for numeric literals.
1476
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#numeric-literal-prefixes
1477
+ Enabled: true
1478
+
1479
+ Style/NumericPredicate:
1480
+ Description: Checks for the use of predicate- or comparison methods for numeric comparisons.
1481
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#predicate-methods
1482
+ AutoCorrect: false
1483
+ Enabled: true
1484
+
599
1485
  Style/OneLineConditional:
600
1486
  Description: Favor the ternary operator(?:) over if/then/else/end constructs.
601
1487
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#ternary-operator
602
1488
  Enabled: false
603
- Style/OpMethod:
604
- Description: When defining binary operators, name the argument other.
605
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#other-arg
606
- Enabled: false
1489
+
607
1490
  Style/OptionalArguments:
608
- Description: Checks for optional arguments that do not appear at the end of the
609
- argument list
1491
+ Description: Checks for optional arguments that do not appear at the end of the argument list
610
1492
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#optional-arguments
611
1493
  Enabled: false
1494
+
1495
+ Style/OptionHash:
1496
+ Description: Don't use option hashes when you can use keyword arguments.
1497
+ Enabled: false
1498
+
1499
+ Style/OrAssignment:
1500
+ Description: Recommend usage of double pipe equals (||=) where applicable.
1501
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#double-pipe-for-uninit
1502
+ Enabled: true
1503
+
612
1504
  Style/ParallelAssignment:
613
- Description: Check for simple usages of parallel assignment. It will only warn when
614
- the number of variables matches on both sides of the assignment. This also provides
615
- performance benefits
1505
+ Description: Check for simple usages of parallel assignment. It will only warn when the number of variables matches on both sides of the assignment.
616
1506
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#parallel-assignment
617
1507
  Enabled: false
1508
+
618
1509
  Style/ParenthesesAroundCondition:
619
1510
  Description: Don't use parentheses around the condition of an if/unless/while.
620
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-parens-if
1511
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-parens-around-condition
621
1512
  Enabled: true
1513
+
622
1514
  Style/PercentLiteralDelimiters:
623
1515
  Description: Use `%`-literal delimiters consistently
624
1516
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#percent-literal-braces
625
1517
  Enabled: true
1518
+
626
1519
  Style/PercentQLiterals:
627
1520
  Description: Checks if uses of %Q/%q match the configured preference.
628
1521
  Enabled: true
1522
+
629
1523
  Style/PerlBackrefs:
630
1524
  Description: Avoid Perl-style regex back references.
631
1525
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-perl-regexp-last-matchers
632
1526
  Enabled: false
633
- Style/PredicateName:
634
- Description: Check the names of predicate methods.
635
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#bool-methods-qmark
1527
+
1528
+ Style/PreferredHashMethods:
1529
+ Description: Checks use of `has_key?` and `has_value?` Hash methods.
1530
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#hash-key
636
1531
  Enabled: true
1532
+
637
1533
  Style/Proc:
638
1534
  Description: Use proc instead of Proc.new.
639
1535
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#proc
640
1536
  Enabled: true
1537
+
641
1538
  Style/RaiseArgs:
642
1539
  Description: Checks the arguments passed to raise/fail.
643
1540
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#exception-class-messages
644
1541
  Enabled: false
1542
+
645
1543
  Style/RedundantBegin:
646
1544
  Description: Don't use begin blocks when they are not needed.
647
1545
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#begin-implicit
648
1546
  Enabled: true
1547
+
1548
+ Style/RedundantConditional:
1549
+ Description: Don't return true/false from a conditional.
1550
+ Enabled: true
1551
+
649
1552
  Style/RedundantException:
650
1553
  Description: Checks for an obsolete RuntimeException argument in raise/fail.
651
1554
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-explicit-runtimeerror
652
1555
  Enabled: true
1556
+
1557
+ Style/RedundantFreeze:
1558
+ Description: Checks usages of Object#freeze on immutable objects.
1559
+ Enabled: true
1560
+
1561
+ Style/RedundantParentheses:
1562
+ Description: Checks for parentheses that seem not to serve any purpose.
1563
+ Enabled: true
1564
+
653
1565
  Style/RedundantReturn:
654
1566
  Description: Don't use return where it's not required.
655
1567
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-explicit-return
656
1568
  Enabled: true
1569
+
657
1570
  Style/RedundantSelf:
658
1571
  Description: Don't use self where it's not needed.
659
1572
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-self-unless-required
660
1573
  Enabled: true
1574
+
661
1575
  Style/RegexpLiteral:
662
1576
  Description: Use / or %r around regular expressions.
663
1577
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#percent-r
664
1578
  Enabled: false
665
- Style/RescueEnsureAlignment:
666
- Description: Align rescues and ensures correctly.
667
- Enabled: false
1579
+
668
1580
  Style/RescueModifier:
669
1581
  Description: Avoid using rescue in its modifier form.
670
1582
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-rescue-modifiers
671
1583
  Enabled: false
1584
+
1585
+ Style/ReturnNil:
1586
+ Description: Use return instead of return nil.
1587
+ Enabled: false
1588
+
1589
+ Style/SafeNavigation:
1590
+ Description: This cop transforms usages of a method call safeguarded by a check for the existance of the object to safe navigation (`&.`).
1591
+ Enabled: true
1592
+
672
1593
  Style/SelfAssignment:
673
- Description: Checks for places where self-assignment shorthand should have been
674
- used.
1594
+ Description: Checks for places where self-assignment shorthand should have been used.
675
1595
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#self-assignment
676
1596
  Enabled: true
1597
+
677
1598
  Style/Semicolon:
678
1599
  Description: Don't use semicolons to terminate expressions.
679
1600
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-semicolon
680
1601
  Enabled: true
1602
+
1603
+ Style/Send:
1604
+ Description: Prefer `Object#__send__` or `Object#public_send` to `send`, as `send` may overlap with existing methods.
1605
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#prefer-public-send
1606
+ Enabled: false
1607
+
681
1608
  Style/SignalException:
682
1609
  Description: Checks for proper usage of fail and raise.
683
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#fail-method
1610
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#prefer-raise-over-fail
684
1611
  Enabled: true
1612
+
685
1613
  Style/SingleLineBlockParams:
686
1614
  Description: Enforces the names of some block params.
687
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#reduce-blocks
688
- Enabled: true
1615
+ Enabled: false
1616
+
689
1617
  Style/SingleLineMethods:
690
1618
  Description: Avoid single-line methods.
691
1619
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-single-line-methods
692
1620
  Enabled: false
693
- Style/SpaceBeforeFirstArg:
694
- Description: Checks that exactly one space is used between a method name and the
695
- first argument for method calls without parentheses.
696
- Enabled: true
697
- Style/SpaceAfterColon:
698
- Description: Use spaces after colons.
699
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-operators
700
- Enabled: true
701
- Style/SpaceAfterComma:
702
- Description: Use spaces after commas.
703
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-operators
704
- Enabled: true
705
- Style/SpaceAroundKeyword:
706
- Description: Use spaces around keywords.
707
- Enabled: true
708
- Style/SpaceAfterMethodName:
709
- Description: Do not put a space between a method name and the opening parenthesis
710
- in a method definition.
711
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#parens-no-spaces
712
- Enabled: true
713
- Style/SpaceAfterNot:
714
- Description: Tracks redundant space after the ! operator.
715
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-space-bang
716
- Enabled: false
717
- Style/SpaceAfterSemicolon:
718
- Description: Use spaces after semicolons.
719
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-operators
720
- Enabled: true
721
- Style/SpaceBeforeBlockBraces:
722
- Description: Checks that the left block brace has or doesn't have space before it.
723
- Enabled: false
724
- Style/SpaceBeforeComma:
725
- Description: No spaces before commas.
726
- Enabled: false
727
- Style/SpaceBeforeComment:
728
- Description: Checks for missing space between code and a comment on the same line.
729
- Enabled: false
730
- Style/SpaceBeforeSemicolon:
731
- Description: No spaces before semicolons.
732
- Enabled: false
733
- Style/SpaceInsideBlockBraces:
734
- Description: Checks that block braces have or don't have surrounding space. For
735
- blocks taking parameters, checks that the left brace has or doesn't have trailing
736
- space.
737
- Enabled: false
738
- Style/SpaceAroundBlockParameters:
739
- Description: Checks the spacing inside and after block parameters pipes.
740
- Enabled: true
741
- Style/SpaceAroundEqualsInParameterDefault:
742
- Description: Checks that the equals signs in parameter default assignments have
743
- or don't have surrounding space depending on configuration.
744
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-around-equals
745
- Enabled: true
746
- Style/SpaceAroundOperators:
747
- Description: Use a single space around operators.
748
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-operators
749
- Enabled: true
750
- Style/SpaceInsideBrackets:
751
- Description: No spaces after [ or before ].
752
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-spaces-braces
753
- Enabled: false
754
- Style/SpaceInsideHashLiteralBraces:
755
- Description: Use spaces inside hash literal braces - or don't.
756
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-operators
757
- Enabled: false
758
- Style/SpaceInsideParens:
759
- Description: No spaces after ( or before ).
760
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-spaces-braces
761
- Enabled: true
762
- Style/SpaceInsideRangeLiteral:
763
- Description: No spaces inside range literals.
764
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-space-inside-range-literals
765
- Enabled: true
766
- Style/SpaceInsideStringInterpolation:
767
- Description: Checks for padding/surrounding spaces inside string interpolation.
768
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#string-interpolation
769
- Enabled: false
1621
+
770
1622
  Style/SpecialGlobalVars:
771
1623
  Description: Avoid Perl-style global variables.
772
1624
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-cryptic-perlisms
773
1625
  Enabled: false
1626
+
1627
+ Style/StabbyLambdaParentheses:
1628
+ Description: Check for the usage of parentheses around stabby lambda arguments.
1629
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#stabby-lambda-with-args
1630
+ Enabled: true
1631
+
1632
+ Style/StderrPuts:
1633
+ Description: Use `warn` instead of `$stderr.puts`.
1634
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#warn
1635
+ Enabled: true
1636
+
774
1637
  Style/StringLiterals:
775
1638
  Description: Checks if uses of quotes match the configured preference.
776
1639
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#consistent-string-literals
777
1640
  EnforcedStyle: double_quotes
778
1641
  Enabled: true
1642
+
779
1643
  Style/StringLiteralsInInterpolation:
780
- Description: Checks if uses of quotes inside expressions in interpolated strings
781
- match the configured preference.
1644
+ Description: Checks if uses of quotes inside expressions in interpolated strings match the configured preference.
782
1645
  Enabled: true
1646
+
1647
+ Style/StringMethods:
1648
+ Description: Checks if configured preferred methods are used over non-preferred.
1649
+ Enabled: false
1650
+
783
1651
  Style/StructInheritance:
784
1652
  Description: Checks for inheritance from Struct.new.
785
1653
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-extend-struct-new
786
1654
  Enabled: false
1655
+
1656
+ Style/SymbolArray:
1657
+ Description: Use %i or %I for arrays of symbols.
1658
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#percent-i
1659
+ Enabled: true
1660
+
787
1661
  Style/SymbolLiteral:
788
1662
  Description: Use plain symbols instead of string symbols when possible.
789
1663
  Enabled: false
1664
+
790
1665
  Style/SymbolProc:
791
1666
  Description: Use symbols as procs instead of blocks when possible.
792
1667
  Enabled: false
793
- Style/Tab:
794
- Description: No hard tabs.
795
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-indentation
796
- Enabled: false
797
- Style/TrailingBlankLines:
798
- Description: Checks trailing blank lines and final newline.
799
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#newline-eof
800
- Enabled: false
1668
+
1669
+ Style/TernaryParentheses:
1670
+ Description: Checks for use of parentheses around ternary conditions.
1671
+ Enabled: true
1672
+
1673
+ Style/MixinUsage:
1674
+ Description: Checks that `include`, `extend` and `prepend` exists at the top level.
1675
+ Enabled: true
1676
+
801
1677
  Style/TrailingCommaInArguments:
802
- Description: Checks for trailing comma in parameter lists.
803
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-trailing-params-comma
1678
+ Description: Checks for trailing comma in argument lists.
1679
+ StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-trailing-params-comma'
804
1680
  Enabled: false
1681
+
805
1682
  Style/TrailingCommaInLiteral:
806
- Description: Checks for trailing comma in literals.
1683
+ Description: Checks for trailing comma in array and hash literals.'
807
1684
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-trailing-array-commas
808
1685
  Enabled: false
809
- Style/TrailingWhitespace:
810
- Description: Avoid trailing whitespace.
811
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-trailing-whitespace
812
- Enabled: false
1686
+
813
1687
  Style/TrivialAccessors:
814
1688
  Description: Prefer attr_* methods to trivial readers/writers.
815
1689
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#attr_family
816
1690
  Enabled: false
1691
+
817
1692
  Style/UnlessElse:
818
1693
  Description: Do not use unless with else. Rewrite these with the positive case first.
819
1694
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-else-with-unless
820
1695
  Enabled: true
1696
+
821
1697
  Style/UnneededCapitalW:
822
1698
  Description: Checks for %W when interpolation is not needed.
823
1699
  Enabled: false
1700
+
1701
+ Style/UnneededInterpolation:
1702
+ Description: Checks for strings that are just an interpolated expression.
1703
+ Enabled: true
1704
+
824
1705
  Style/UnneededPercentQ:
825
1706
  Description: Checks for %q/%Q when single quotes or double quotes would do.
826
1707
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#percent-q
827
1708
  Enabled: false
1709
+
828
1710
  Style/TrailingUnderscoreVariable:
829
- Description: Checks for the usage of unneeded trailing underscores at the end of
830
- parallel variable assignment.
1711
+ Description: Checks for the usage of unneeded trailing underscores at the end of parallel variable assignment.
1712
+ AllowNamedUnderscoreVariables: true
831
1713
  Enabled: false
1714
+
832
1715
  Style/VariableInterpolation:
833
- Description: Don't interpolate global, instance and class variables directly in
834
- strings.
1716
+ Description: Don't interpolate global, instance and class variables directly in strings.
835
1717
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#curlies-interpolate
836
1718
  Enabled: true
837
- Style/VariableName:
838
- Description: Use the configured style when naming variables.
839
- StyleGuide: https://github.com/bbatsov/ruby-style-guide#snake-case-symbols-methods-vars
840
- Enabled: true
1719
+
841
1720
  Style/WhenThen:
842
1721
  Description: Use when x then ... for one-line cases.
843
1722
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#one-line-cases
844
1723
  Enabled: true
1724
+
845
1725
  Style/WhileUntilDo:
846
1726
  Description: Checks for redundant do after while or until.
847
1727
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-multiline-while-do
848
1728
  Enabled: true
1729
+
849
1730
  Style/WhileUntilModifier:
850
1731
  Description: Favor modifier while/until usage when you have a single-line body.
851
1732
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#while-as-a-modifier
852
1733
  Enabled: true
853
- Style/MutableConstant:
854
- Enabled: true
855
- Style/FrozenStringLiteralComment:
856
- Enabled: true
1734
+
857
1735
  Style/WordArray:
858
1736
  Description: Use %w or %W for arrays of words.
859
1737
  StyleGuide: https://github.com/bbatsov/ruby-style-guide#percent-w
860
1738
  Enabled: true
861
- Style/EmptyMethod:
862
- Enabled: false
863
- Security/Eval:
864
- Description: The use of eval represents a serious security risk.
1739
+
1740
+ Style/YodaCondition:
1741
+ Description: Do not use literals as the first operand of a comparison.
1742
+ Reference: https://en.wikipedia.org/wiki/Yoda_conditions
1743
+ Enabled: true
1744
+
1745
+ Style/ZeroLengthPredicate:
1746
+ Description: Use #empty? when testing for objects of length 0.
865
1747
  Enabled: true