onkcop 0.50.0.0 → 0.51.0.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/rails.yml +8 -0
- data/config/rubocop.yml +12 -2
- data/lib/onkcop/version.rb +1 -1
- data/onkcop.gemspec +2 -2
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7f59f884ff0507d3ba72afc6f7ee3187326786bf5f33d1bb60c7d3457c75b257
|
4
|
+
data.tar.gz: 9c5304a8a8327be1226f73821d7675b5ebbde57a70d1bcefeb1656ac1efc5fd2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c1bc840d525ce5855b3f6317a8f7ab900277a0ac7fed63d6596856b800ec1e429a3454a7e3399190a07496bf743717a80a9350c6cfc0c02c36900c4b88e5534f
|
7
|
+
data.tar.gz: 635e0dbfe39584f3aaa9f47e2bb547af1b8e5b2e693629c65cf32fa172bd38f2f4dc5e4207197f9b1eab8d050d47bfe526a300291ebd036960a366a19b47ffc5
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,13 @@
|
|
1
1
|
# onkcop
|
2
2
|
|
3
|
+
## v0.51.0.0 (2017-10-20)
|
4
|
+
|
5
|
+
* Update `rubocop` v0.51.0 and `rubocop-rspec` v1.19.0
|
6
|
+
* Enable `Lint/ReturnInVoidContext` cop
|
7
|
+
* Add `staging` env to `Rails/UnknownEnv` cop
|
8
|
+
* Add comments to `Style/SafeNavigation` and `Lint/UnusedMethodArgument` cop
|
9
|
+
|
10
|
+
|
3
11
|
## v0.50.0.0 (2017-10-12)
|
4
12
|
|
5
13
|
* Update `rubocop` v0.50.0 and `rubocop-rspec` v1.18.0
|
data/config/rails.yml
CHANGED
@@ -13,3 +13,11 @@ Rails/SafeNavigation:
|
|
13
13
|
# valid? チェックし忘れを防ぎたい
|
14
14
|
Rails/SaveBang:
|
15
15
|
Enabled: true
|
16
|
+
|
17
|
+
# staging 環境を使っているので追加
|
18
|
+
Rails/UnknownEnv:
|
19
|
+
Environments:
|
20
|
+
- development # rubocop default.yml
|
21
|
+
- test # rubocop default.yml
|
22
|
+
- production # rubocop default.yml
|
23
|
+
- staging
|
data/config/rubocop.yml
CHANGED
@@ -186,7 +186,14 @@ Style/RedundantReturn:
|
|
186
186
|
Style/RedundantSelf:
|
187
187
|
Enabled: false
|
188
188
|
|
189
|
-
#
|
189
|
+
# user&.admin? が、[nil, true, false] の 3 値を返すことに一瞬で気づけず
|
190
|
+
# boolean を返すっぽく見えてしまうので無効に。
|
191
|
+
# user && user.admin? なら短絡評価で nil が返ってくるのが一目で分かるので。
|
192
|
+
# (boolean を返すメソッド以外なら積極的に使いたいんだけどねぇ
|
193
|
+
#
|
194
|
+
# 他に auto-correct してはいけないパターンとして
|
195
|
+
# if hoge && hoge.count > 1
|
196
|
+
# がある。
|
190
197
|
Style/SafeNavigation:
|
191
198
|
Enabled: false
|
192
199
|
|
@@ -310,7 +317,10 @@ Lint/RescueWithoutErrorClass:
|
|
310
317
|
Lint/UnderscorePrefixedVariableName:
|
311
318
|
Enabled: false
|
312
319
|
|
313
|
-
#
|
320
|
+
# 子クラスで実装させるつもりで中身が
|
321
|
+
# raise NotImplementedError
|
322
|
+
# のみのメソッドが引っかかるので。
|
323
|
+
# (raise せずに中身が空だと IgnoreEmptyMethods でセーフ)
|
314
324
|
Lint/UnusedMethodArgument:
|
315
325
|
Enabled: false
|
316
326
|
|
data/lib/onkcop/version.rb
CHANGED
data/onkcop.gemspec
CHANGED
@@ -19,8 +19,8 @@ Gem::Specification.new do |spec|
|
|
19
19
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
20
20
|
spec.require_paths = ["lib"]
|
21
21
|
|
22
|
-
spec.add_dependency "rubocop", "~> 0.
|
23
|
-
spec.add_dependency "rubocop-rspec", ">= 1.
|
22
|
+
spec.add_dependency "rubocop", "~> 0.51.0"
|
23
|
+
spec.add_dependency "rubocop-rspec", ">= 1.19.0"
|
24
24
|
spec.add_development_dependency "bundler"
|
25
25
|
spec.add_development_dependency "rake"
|
26
26
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: onkcop
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.51.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Takafumi ONAKA
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-10-
|
11
|
+
date: 2017-10-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rubocop
|
@@ -16,28 +16,28 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 0.
|
19
|
+
version: 0.51.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.51.0
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: rubocop-rspec
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 1.
|
33
|
+
version: 1.19.0
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: 1.
|
40
|
+
version: 1.19.0
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: bundler
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|