finstyle 1.3.0 → 1.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +8 -0
- data/config/disabled.yml +5 -0
- data/config/enabled.yml +15 -7
- data/config/finstyle.yml +10 -8
- data/config/upstream.yml +15 -1
- data/finstyle.gemspec +1 -1
- data/lib/finstyle/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 84538f975b126cba240de14cd84c5e779af130d2
|
4
|
+
data.tar.gz: 2dd8828b126037fab9cfcd9d9a509a33ce6a05c8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0000b23989b5942d3793bf9ef4fa31711d051d5d0b8ffdc49590192403496e582d1ba1959ff5b4c9d3efe8698a96bd3d8c9e850a697918d521b30611dd4686e4
|
7
|
+
data.tar.gz: 9025636bf7b8334f60e984f3633597177ab13e61fee82bd5a06d7eb2f4cd7bb5f4591d3ec87b64cd4b4a9364bc4a7a56079440c129e378f45434a886eaa01e1a
|
data/CHANGELOG.md
CHANGED
data/config/disabled.yml
CHANGED
data/config/enabled.yml
CHANGED
@@ -87,7 +87,7 @@ Style/Blocks:
|
|
87
87
|
Enabled: true
|
88
88
|
|
89
89
|
Style/BracesAroundHashParameters:
|
90
|
-
Description: 'Enforce braces style
|
90
|
+
Description: 'Enforce braces style around hash parameters.'
|
91
91
|
Enabled: true
|
92
92
|
|
93
93
|
Style/CaseEquality:
|
@@ -181,6 +181,10 @@ Style/ElseAlignment:
|
|
181
181
|
Description: 'Align elses and elsifs correctly.'
|
182
182
|
Enabled: true
|
183
183
|
|
184
|
+
Style/EmptyElse:
|
185
|
+
Description: 'Avoid empty else-clauses.'
|
186
|
+
Enabled: true
|
187
|
+
|
184
188
|
Style/EmptyLineBetweenDefs:
|
185
189
|
Description: 'Use empty lines between defs.'
|
186
190
|
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#empty-lines-between-methods'
|
@@ -194,6 +198,10 @@ Style/EmptyLinesAroundAccessModifier:
|
|
194
198
|
Description: "Keep blank lines around access modifiers."
|
195
199
|
Enabled: true
|
196
200
|
|
201
|
+
Style/EmptyLinesAroundBlockBody:
|
202
|
+
Description: "Keeps track of empty lines around block bodies."
|
203
|
+
Enabled: true
|
204
|
+
|
197
205
|
Style/EmptyLinesAroundClassBody:
|
198
206
|
Description: "Keeps track of empty lines around class bodies."
|
199
207
|
Enabled: true
|
@@ -271,7 +279,7 @@ Style/IfUnlessModifier:
|
|
271
279
|
Enabled: true
|
272
280
|
|
273
281
|
Style/IfWithSemicolon:
|
274
|
-
Description: '
|
282
|
+
Description: 'Do not use if x; .... Use the ternary operator instead.'
|
275
283
|
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-semicolon-ifs'
|
276
284
|
Enabled: true
|
277
285
|
|
@@ -352,7 +360,7 @@ Style/MultilineBlockLayout:
|
|
352
360
|
Enabled: true
|
353
361
|
|
354
362
|
Style/MultilineIfThen:
|
355
|
-
Description: '
|
363
|
+
Description: 'Do not use then for multi-line if/unless.'
|
356
364
|
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-then'
|
357
365
|
Enabled: true
|
358
366
|
|
@@ -544,7 +552,7 @@ Style/SpaceAfterControlKeyword:
|
|
544
552
|
|
545
553
|
Style/SpaceAfterMethodName:
|
546
554
|
Description: >-
|
547
|
-
|
555
|
+
Do not put a space between a method name and the opening
|
548
556
|
parenthesis in a method definition.
|
549
557
|
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#parens-no-spaces'
|
550
558
|
Enabled: true
|
@@ -670,7 +678,7 @@ Style/TrivialAccessors:
|
|
670
678
|
|
671
679
|
Style/UnlessElse:
|
672
680
|
Description: >-
|
673
|
-
|
681
|
+
Do not use unless with else. Rewrite these with the positive
|
674
682
|
case first.
|
675
683
|
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-else-with-unless'
|
676
684
|
Enabled: true
|
@@ -742,7 +750,7 @@ Metrics/ClassLength:
|
|
742
750
|
|
743
751
|
Metrics/CyclomaticComplexity:
|
744
752
|
Description: >-
|
745
|
-
A complexity metric that is
|
753
|
+
A complexity metric that is strongly correlated to the number
|
746
754
|
of test cases needed to validate a method.
|
747
755
|
Enabled: true
|
748
756
|
|
@@ -832,7 +840,7 @@ Lint/EndInMethod:
|
|
832
840
|
Enabled: true
|
833
841
|
|
834
842
|
Lint/EnsureReturn:
|
835
|
-
Description: '
|
843
|
+
Description: 'Do not use return in an ensure block.'
|
836
844
|
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-return-ensure'
|
837
845
|
Enabled: true
|
838
846
|
|
data/config/finstyle.yml
CHANGED
@@ -50,6 +50,9 @@ Style/AlignParameters:
|
|
50
50
|
Style/Blocks:
|
51
51
|
Enabled: false
|
52
52
|
|
53
|
+
BracesAroundHashParameters:
|
54
|
+
EnforcedStyle: context_dependent
|
55
|
+
|
53
56
|
# Words help us convey meaning and Ruby aliased methods help with this.
|
54
57
|
Style/CollectionMethods:
|
55
58
|
PreferredMethods:
|
@@ -66,14 +69,16 @@ Style/DotPosition:
|
|
66
69
|
Style/EachWithObject:
|
67
70
|
Enabled: false
|
68
71
|
|
69
|
-
#
|
70
|
-
#
|
71
|
-
|
72
|
-
Style/ElseAlignment:
|
72
|
+
# In cases where this has come up, else blocks typically contain an explicit
|
73
|
+
# nil value which can reduce certain future return clause bugs
|
74
|
+
Style/EmptyElse:
|
73
75
|
Enabled: false
|
74
76
|
|
75
77
|
# Whitespace between modules/classes/methods can be helpful to read and
|
76
78
|
# don't hurt anybody.
|
79
|
+
Style/EmptyLinesAroundBlockBody:
|
80
|
+
Enabled: false
|
81
|
+
|
77
82
|
Style/EmptyLinesAroundClassBody:
|
78
83
|
Enabled: false
|
79
84
|
|
@@ -141,11 +146,8 @@ Style/SignalException:
|
|
141
146
|
Style/StringLiterals:
|
142
147
|
EnforcedStyle: double_quotes
|
143
148
|
|
144
|
-
# Temporarily disabled, pending releas of Rubocop later than 0.27.0, which
|
145
|
-
# includes https://github.com/bbatsov/rubocop/issues/1415 fix
|
146
|
-
# @TODO Remve when Rubocop > 0.27.0 is released.
|
147
149
|
Style/StringLiteralsInInterpolation:
|
148
|
-
|
150
|
+
EnforcedStyle: double_quotes
|
149
151
|
|
150
152
|
# Nothing but a single-quoting strings rule in disguise
|
151
153
|
Style/UnneededCapitalW:
|
data/config/upstream.yml
CHANGED
@@ -139,8 +139,16 @@ Style/BarePercentLiterals:
|
|
139
139
|
Style/BracesAroundHashParameters:
|
140
140
|
EnforcedStyle: no_braces
|
141
141
|
SupportedStyles:
|
142
|
+
# The `braces` style enforces braces around all method parameters that are
|
143
|
+
# hashes.
|
142
144
|
- braces
|
145
|
+
# The `no_braces` style checks that the last parameter doesn't have braces
|
146
|
+
# around it.
|
143
147
|
- no_braces
|
148
|
+
# The `context_dependent` style checks that the last parameter doesn't have
|
149
|
+
# braces around it, but requires braces if the second to last parameter is
|
150
|
+
# also a hash literal.
|
151
|
+
- context_dependent
|
144
152
|
|
145
153
|
# Indentation of `when`.
|
146
154
|
Style/CaseIndentation:
|
@@ -214,6 +222,12 @@ Style/EmptyLineBetweenDefs:
|
|
214
222
|
# need an empty line between them.
|
215
223
|
AllowAdjacentOneLineDefs: false
|
216
224
|
|
225
|
+
Style/EmptyLinesAroundBlockBody:
|
226
|
+
EnforcedStyle: no_empty_lines
|
227
|
+
SupportedStyles:
|
228
|
+
- empty_lines
|
229
|
+
- no_empty_lines
|
230
|
+
|
217
231
|
Style/EmptyLinesAroundClassBody:
|
218
232
|
EnforcedStyle: no_empty_lines
|
219
233
|
SupportedStyles:
|
@@ -605,7 +619,7 @@ Rails/Output:
|
|
605
619
|
- config/**/*.rb
|
606
620
|
- db/**/*.rb
|
607
621
|
- lib/**/*.rb
|
608
|
-
|
622
|
+
|
609
623
|
Rails/ReadWriteAttribute:
|
610
624
|
Include:
|
611
625
|
- app/models/**/*.rb
|
data/finstyle.gemspec
CHANGED
@@ -21,7 +21,7 @@ Gem::Specification.new do |spec|
|
|
21
21
|
|
22
22
|
spec.required_ruby_version = ">= 1.9.3"
|
23
23
|
|
24
|
-
spec.add_dependency("rubocop", "0.
|
24
|
+
spec.add_dependency("rubocop", "0.28.0")
|
25
25
|
|
26
26
|
spec.add_development_dependency("bundler", "~> 1.6")
|
27
27
|
spec.add_development_dependency("rake", "~> 10.0")
|
data/lib/finstyle/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: finstyle
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fletcher Nichol
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-12-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rubocop
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - '='
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 0.
|
19
|
+
version: 0.28.0
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - '='
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 0.
|
26
|
+
version: 0.28.0
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: bundler
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|