meowcop 2.8.0 → 2.13.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1dc79b2c53c347d33980e62c9e589fc11e654f6678ade6b4577f7f76dd260b8f
4
- data.tar.gz: 7caff16004738158ca05cf48f06e3d6c9be25c61fe0d78d2cc093667ec785656
3
+ metadata.gz: e75820ead7209002c4499e5e22276d9c497f0644a7f4e1f52916bd527a269599
4
+ data.tar.gz: bc415579d007e1c2ed5831f514212fcfdf4c8883f2075757af4606f7845a6957
5
5
  SHA512:
6
- metadata.gz: df8731db44bc3ebffc6aba5199599c61f56fde4034032d2bb4cf62bfbc8736cba7a5c18d779aeb5931eb7448a4269c6a3fbb872bcf85c218d184ca22e5694e75
7
- data.tar.gz: c9fbcd8528ae464bf3b4475fa31f899e21244f87ab38eb8f4d344f5314b80f9750250b251d2a9b653aa963974740c24e7b3b2497a7b963f4c12064ec2d3272d8
6
+ metadata.gz: 9b57407ea836ecacf063924b3cae41699a5709dd6259faa94307b27950e26bcaa2064a40e0959e9f1edd8062ea43b637453da99ac7fe529178fbddf78c7b2b7e
7
+ data.tar.gz: a7fecf64f6d3788c0bfd9479909231e16157552829b8be9f12cbe52ee076a1970a5434e22213189c84bc639ad21b361a875fc10b40b2840e0f629373c728a0d3
data/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
  [![Gem Version](https://badge.fury.io/rb/meowcop.svg)](https://badge.fury.io/rb/meowcop)
4
4
 
5
5
  MeowCop is a gem for shareable [RuboCop](https://www.rubocop.org) configuration, it focuses [Lint](https://en.wikipedia.org/wiki/Lint_(software)).
6
- It's recommended by Sider, Inc.
6
+ It's recommended by Sider.
7
7
 
8
8
  ## Design
9
9
 
@@ -106,6 +106,8 @@ Layout/EmptyLineAfterGuardClause:
106
106
  Enabled: false
107
107
  Layout/EmptyLinesAroundAccessModifier:
108
108
  Enabled: false
109
+ Layout/EmptyLinesAroundAttributeAccessor:
110
+ Enabled: false
109
111
  Layout/EmptyLinesAroundBeginBody:
110
112
  Enabled: false
111
113
  Layout/EmptyLinesAroundBlockBody:
@@ -180,6 +182,8 @@ Layout/SpaceAroundEqualsInParameterDefault:
180
182
  Enabled: false
181
183
  Layout/SpaceAroundKeyword:
182
184
  Enabled: false
185
+ Layout/SpaceAroundMethodCallOperator:
186
+ Enabled: false
183
187
  Layout/SpaceAroundOperators:
184
188
  Enabled: false
185
189
  Layout/SpaceBeforeBlockBraces:
@@ -256,10 +260,14 @@ Naming/MethodParameterName:
256
260
  # === Disabled cops: BEGIN ===
257
261
  Style/AccessModifierDeclarations:
258
262
  Enabled: false
263
+ Style/AccessorGrouping:
264
+ Enabled: false
259
265
  Style/Alias:
260
266
  Enabled: false
261
267
  Style/AndOr:
262
268
  Enabled: false
269
+ Style/ArrayCoercion:
270
+ Enabled: false
263
271
  Style/ArrayJoin:
264
272
  Enabled: false
265
273
  Style/AsciiComments:
@@ -272,12 +280,16 @@ Style/BarePercentLiterals:
272
280
  Enabled: false
273
281
  Style/BeginBlock:
274
282
  Enabled: false
283
+ Style/BisectedAttrAccessor:
284
+ Enabled: false
275
285
  Style/BlockComments:
276
286
  Enabled: false
277
287
  Style/BlockDelimiters:
278
288
  Enabled: false
279
289
  Style/CaseEquality:
280
290
  Enabled: false
291
+ Style/CaseLikeIf:
292
+ Enabled: false
281
293
  Style/CharacterLiteral:
282
294
  Enabled: false
283
295
  Style/ClassAndModuleChildren:
@@ -312,6 +324,8 @@ Style/DefWithParentheses:
312
324
  Enabled: false
313
325
  Style/Dir:
314
326
  Enabled: false
327
+ Style/DisableCopsWithinSourceCodeDirective:
328
+ Enabled: false
315
329
  Style/Documentation:
316
330
  Enabled: false
317
331
  Style/DocumentationMethod:
@@ -346,6 +360,10 @@ Style/EvenOdd:
346
360
  Enabled: false
347
361
  Style/ExpandPathArguments:
348
362
  Enabled: false
363
+ Style/ExplicitBlockArgument:
364
+ Enabled: false
365
+ Style/ExponentialNotation:
366
+ Enabled: false
349
367
  Style/FloatDivision:
350
368
  Enabled: false
351
369
  Style/For:
@@ -356,12 +374,18 @@ Style/FormatStringToken:
356
374
  Enabled: false
357
375
  Style/FrozenStringLiteralComment:
358
376
  Enabled: false
377
+ Style/GlobalStdStream:
378
+ Enabled: false
359
379
  Style/GlobalVars:
360
380
  Enabled: false
361
381
  Style/GuardClause:
362
382
  Enabled: false
383
+ Style/HashAsLastArrayItem:
384
+ Enabled: false
363
385
  Style/HashEachMethods:
364
386
  Enabled: false
387
+ Style/HashLikeCase:
388
+ Enabled: false
365
389
  Style/HashSyntax:
366
390
  Enabled: false
367
391
  Style/HashTransformKeys:
@@ -402,8 +426,6 @@ Style/MethodCalledOnDoEndBlock:
402
426
  Enabled: false
403
427
  Style/MethodDefParentheses:
404
428
  Enabled: false
405
- Style/MethodMissingSuper:
406
- Enabled: false
407
429
  Style/MinMax:
408
430
  Enabled: false
409
431
  Style/MissingElse:
@@ -466,6 +488,8 @@ Style/OptionHash:
466
488
  Enabled: false
467
489
  Style/OptionalArguments:
468
490
  Enabled: false
491
+ Style/OptionalBooleanParameter:
492
+ Enabled: false
469
493
  Style/OrAssignment:
470
494
  Enabled: false
471
495
  Style/ParallelAssignment:
@@ -486,6 +510,8 @@ Style/RaiseArgs:
486
510
  Enabled: false
487
511
  Style/RandomWithOffset:
488
512
  Enabled: false
513
+ Style/RedundantAssignment:
514
+ Enabled: false
489
515
  Style/RedundantBegin:
490
516
  Enabled: false
491
517
  Style/RedundantCapitalW:
@@ -496,6 +522,10 @@ Style/RedundantConditional:
496
522
  Enabled: false
497
523
  Style/RedundantException:
498
524
  Enabled: false
525
+ Style/RedundantFetchBlock:
526
+ Enabled: false
527
+ Style/RedundantFileExtensionInRequire:
528
+ Enabled: false
499
529
  Style/RedundantFreeze:
500
530
  Enabled: false
501
531
  Style/RedundantInterpolation:
@@ -504,6 +534,10 @@ Style/RedundantParentheses:
504
534
  Enabled: false
505
535
  Style/RedundantPercentQ:
506
536
  Enabled: false
537
+ Style/RedundantRegexpCharacterClass:
538
+ Enabled: false
539
+ Style/RedundantRegexpEscape:
540
+ Enabled: false
507
541
  Style/RedundantReturn:
508
542
  Enabled: false
509
543
  Style/RedundantSelf:
@@ -532,16 +566,22 @@ Style/Send:
532
566
  Enabled: false
533
567
  Style/SignalException:
534
568
  Enabled: false
569
+ Style/SingleArgumentDig:
570
+ Enabled: false
535
571
  Style/SingleLineBlockParams:
536
572
  Enabled: false
537
573
  Style/SingleLineMethods:
538
574
  Enabled: false
575
+ Style/SlicingWithRange:
576
+ Enabled: false
539
577
  Style/SpecialGlobalVars:
540
578
  Enabled: false
541
579
  Style/StabbyLambdaParentheses:
542
580
  Enabled: false
543
581
  Style/StderrPuts:
544
582
  Enabled: false
583
+ Style/StringConcatenation:
584
+ Enabled: false
545
585
  Style/StringLiterals:
546
586
  Enabled: false
547
587
  Style/StringLiteralsInInterpolation:
@@ -570,6 +610,8 @@ Style/TrailingCommaInArguments:
570
610
  Enabled: false
571
611
  Style/TrailingCommaInArrayLiteral:
572
612
  Enabled: false
613
+ Style/TrailingCommaInBlockArgs:
614
+ Enabled: false
573
615
  Style/TrailingCommaInHashLiteral:
574
616
  Enabled: false
575
617
  Style/TrailingMethodEndStatement:
@@ -1,6 +1,9 @@
1
1
  require "meowcop/version"
2
2
  require 'meowcop/cli'
3
3
 
4
- module Meowcop
4
+ module MeowCop
5
5
  # Your code goes here...
6
6
  end
7
+
8
+ # Ensure backward compatibility
9
+ Meowcop = MeowCop
@@ -23,17 +23,24 @@
23
23
  # THE SOFTWARE.
24
24
  require 'fileutils'
25
25
 
26
- module Meowcop
26
+ module MeowCop
27
27
  class CLI
28
28
  CONFIG_FILE_NAME = ".rubocop.yml".freeze
29
29
 
30
+ EXIT_SUCCESS = 0
31
+ EXIT_FAILURE = 1
32
+
33
+ Options = Struct.new(:version, :help)
34
+
30
35
  def self.start(args)
31
36
  action_name = args.shift || 'help'
32
37
 
33
38
  instance = self.new
39
+
34
40
  unless instance.public_methods(false).include?(action_name.to_sym)
35
- puts "Could not find command #{action_name}."
36
- action_name = 'help'
41
+ puts "Could not find command '#{action_name}'."
42
+ instance.help(args)
43
+ return EXIT_FAILURE
37
44
  end
38
45
 
39
46
  instance.public_send(action_name, args)
@@ -44,30 +51,33 @@ module Meowcop
44
51
  FileUtils.copy_file(config_file_path, CONFIG_FILE_NAME)
45
52
  puts "Meow! #{CONFIG_FILE_NAME} has been #{action} successfully."
46
53
 
47
- return 0
54
+ EXIT_SUCCESS
48
55
  end
49
56
 
50
57
  def run(args)
51
58
  require 'rubocop'
52
59
 
53
- cli = RuboCop::CLI.new
54
- args = [
55
- '--config', config_file_path,
56
- *args
57
- ]
58
- cli.run(args)
60
+ RuboCop::CLI.new.run(['--config', config_file_path, *args])
59
61
  end
60
62
 
61
63
  def help(_args)
62
- msg = <<-END
63
- MeowCop commands:
64
- init - Setup .rubocop.yml
65
- help - Show this message
66
- run - Run RuboCop with MeowCop
67
- END
68
- puts msg
69
-
70
- return 0
64
+ puts <<-END
65
+ Usage: meowcop <command>
66
+
67
+ Commands:
68
+ init Setup .rubocop.yml
69
+ run Run RuboCop with MeowCop
70
+ version Show version
71
+ help Show help
72
+ END
73
+
74
+ EXIT_SUCCESS
75
+ end
76
+
77
+ def version(_args)
78
+ puts VERSION
79
+
80
+ EXIT_SUCCESS
71
81
  end
72
82
 
73
83
  private
@@ -1,3 +1,3 @@
1
- module Meowcop
2
- VERSION = "2.8.0".freeze
1
+ module MeowCop
2
+ VERSION = "2.13.0".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: meowcop
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.8.0
4
+ version: 2.13.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sleeek Corporation
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-02-19 00:00:00.000000000 Z
11
+ date: 2020-08-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rubocop
@@ -16,7 +16,7 @@ dependencies:
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: 0.80.0
19
+ version: 0.89.0
20
20
  - - "<"
21
21
  - !ruby/object:Gem::Version
22
22
  version: 1.0.0
@@ -26,7 +26,7 @@ dependencies:
26
26
  requirements:
27
27
  - - ">="
28
28
  - !ruby/object:Gem::Version
29
- version: 0.80.0
29
+ version: 0.89.0
30
30
  - - "<"
31
31
  - !ruby/object:Gem::Version
32
32
  version: 1.0.0
@@ -36,32 +36,26 @@ dependencies:
36
36
  requirements:
37
37
  - - ">="
38
38
  - !ruby/object:Gem::Version
39
- version: '1.12'
40
- - - "<"
41
- - !ruby/object:Gem::Version
42
- version: '3.0'
39
+ version: '2.1'
43
40
  type: :development
44
41
  prerelease: false
45
42
  version_requirements: !ruby/object:Gem::Requirement
46
43
  requirements:
47
44
  - - ">="
48
45
  - !ruby/object:Gem::Version
49
- version: '1.12'
50
- - - "<"
51
- - !ruby/object:Gem::Version
52
- version: '3.0'
46
+ version: '2.1'
53
47
  - !ruby/object:Gem::Dependency
54
48
  name: rake
55
49
  requirement: !ruby/object:Gem::Requirement
56
50
  requirements:
57
- - - "~>"
51
+ - - ">="
58
52
  - !ruby/object:Gem::Version
59
53
  version: '13.0'
60
54
  type: :development
61
55
  prerelease: false
62
56
  version_requirements: !ruby/object:Gem::Requirement
63
57
  requirements:
64
- - - "~>"
58
+ - - ">="
65
59
  - !ruby/object:Gem::Version
66
60
  version: '13.0'
67
61
  - !ruby/object:Gem::Dependency
@@ -70,43 +64,43 @@ dependencies:
70
64
  requirements:
71
65
  - - ">="
72
66
  - !ruby/object:Gem::Version
73
- version: 5.11.3
67
+ version: '5.14'
74
68
  type: :development
75
69
  prerelease: false
76
70
  version_requirements: !ruby/object:Gem::Requirement
77
71
  requirements:
78
72
  - - ">="
79
73
  - !ruby/object:Gem::Version
80
- version: 5.11.3
74
+ version: '5.14'
81
75
  - !ruby/object:Gem::Dependency
82
76
  name: minitest-reporters
83
77
  requirement: !ruby/object:Gem::Requirement
84
78
  requirements:
85
79
  - - ">="
86
80
  - !ruby/object:Gem::Version
87
- version: 1.3.8
81
+ version: '1.4'
88
82
  type: :development
89
83
  prerelease: false
90
84
  version_requirements: !ruby/object:Gem::Requirement
91
85
  requirements:
92
86
  - - ">="
93
87
  - !ruby/object:Gem::Version
94
- version: 1.3.8
88
+ version: '1.4'
95
89
  - !ruby/object:Gem::Dependency
96
90
  name: activesupport
97
91
  requirement: !ruby/object:Gem::Requirement
98
92
  requirements:
99
- - - "<"
93
+ - - ">="
100
94
  - !ruby/object:Gem::Version
101
- version: 6.0.0
95
+ version: '5.2'
102
96
  type: :development
103
97
  prerelease: false
104
98
  version_requirements: !ruby/object:Gem::Requirement
105
99
  requirements:
106
- - - "<"
100
+ - - ">="
107
101
  - !ruby/object:Gem::Version
108
- version: 6.0.0
109
- description: MeowCop is a RuboCop configuration recommended by Sider, Inc.
102
+ version: '5.2'
103
+ description: MeowCop is a RuboCop configuration recommended by Sider.
110
104
  email: support@sider.review
111
105
  executables:
112
106
  - meowcop
@@ -136,14 +130,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
136
130
  requirements:
137
131
  - - ">="
138
132
  - !ruby/object:Gem::Version
139
- version: 2.3.0
133
+ version: 2.4.0
140
134
  required_rubygems_version: !ruby/object:Gem::Requirement
141
135
  requirements:
142
136
  - - ">="
143
137
  - !ruby/object:Gem::Version
144
138
  version: '0'
145
139
  requirements: []
146
- rubygems_version: 3.1.2
140
+ rubygems_version: 3.1.4
147
141
  signing_key:
148
142
  specification_version: 4
149
143
  summary: A RuboCop configuration focusing Lint