perx-rubocop 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +41 -0
- data/default.yml +1 -4
- data/lib/perx/rubocop/version.rb +1 -1
- data/perx-rubocop.gemspec +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0e3667307f34c42681c9cbe1b4d4060cc15334b1fb884f562fcdd2804f87d234
|
4
|
+
data.tar.gz: 5dfd00f9ac9876ef3b58f70c12b999a2b9d21eed8a8843a85dc7775a3f197814
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d42a812fd57d97b451d7fa1df823ecc856bffd9fab2676d214c48cbdb4e9f79bb31d16866c69a45eae764d7f6e28e6d40e89cdc207e93b84242242b48de5faf3
|
7
|
+
data.tar.gz: 57c744a6f2d6e23c1ef1831f4704afeecc57f328de22fd4708681093658931538924f9d050f6a04e02e6b2c52704639358bdc150f58bc29a2214c335fb908b07
|
data/README.md
CHANGED
@@ -35,6 +35,47 @@ inherit_gem:
|
|
35
35
|
This will inherit all the perx-rubocop configurations. In case you need to
|
36
36
|
overwrite any of the rules, the file behaves the same as before.
|
37
37
|
|
38
|
+
### I want to override something
|
39
|
+
|
40
|
+
Simply update your rubocop.yml with your new rule. Take in account that
|
41
|
+
the default mode is overriding the rule and not add to the existing rules.
|
42
|
+
|
43
|
+
E.g
|
44
|
+
|
45
|
+
perx-rubocop defines:
|
46
|
+
|
47
|
+
```
|
48
|
+
Metrics/BlockLength:
|
49
|
+
Exclude:
|
50
|
+
- '**/db/seeds/**/*.rb'
|
51
|
+
- '**/spec/**/*_spec.rb'
|
52
|
+
- '**/spec/factories/**/*.rb'
|
53
|
+
```
|
54
|
+
|
55
|
+
If you were to write in your project's rubocop.yml
|
56
|
+
|
57
|
+
```
|
58
|
+
Metrics/BlockLength:
|
59
|
+
Exclude:
|
60
|
+
- '**/something/**.rb'
|
61
|
+
```
|
62
|
+
|
63
|
+
This would simply override the previously defined behaviour.
|
64
|
+
If you want to add to the existing list of files, you should as well define
|
65
|
+
the merge policy in your rubocop.yml. There are other merge possibilities and
|
66
|
+
you should look at [rubocop's documentation](https://github.com/rubocop-hq/rubocop/blob/master/manual/configuration.md#merging-arrays-using-inherit_mode)
|
67
|
+
for more info.
|
68
|
+
|
69
|
+
```
|
70
|
+
inherit_mode:
|
71
|
+
merge:
|
72
|
+
- Exclude
|
73
|
+
|
74
|
+
Metrics/BlockLength:
|
75
|
+
Exclude:
|
76
|
+
- '**/something/**.rb'
|
77
|
+
```
|
78
|
+
|
38
79
|
## Development
|
39
80
|
|
40
81
|
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
data/default.yml
CHANGED
@@ -22,10 +22,7 @@ Style/SingleLineMethods:
|
|
22
22
|
Metrics/BlockLength:
|
23
23
|
Exclude:
|
24
24
|
- '**/db/seeds/**/*.rb'
|
25
|
-
- '**/spec
|
26
|
-
- '**/spec/policies/**/*.rb'
|
27
|
-
- '**/spec/requests/**/*.rb'
|
28
|
-
- '**/spec/operations/**/*.rb'
|
25
|
+
- '**/spec/**/*_spec.rb'
|
29
26
|
- '**/spec/factories/**/*.rb'
|
30
27
|
Rails/Exit:
|
31
28
|
Exclude:
|
data/lib/perx/rubocop/version.rb
CHANGED
data/perx-rubocop.gemspec
CHANGED
@@ -30,7 +30,7 @@ Gem::Specification.new do |spec|
|
|
30
30
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
31
31
|
spec.require_paths = ['lib']
|
32
32
|
|
33
|
-
spec.add_dependency "rubocop", "~> 0.
|
33
|
+
spec.add_dependency "rubocop", "~> 0.77.0"
|
34
34
|
spec.add_dependency "rubocop-rails", "~> 2.3.2"
|
35
35
|
spec.add_development_dependency 'bundler', '~> 2.0'
|
36
36
|
spec.add_development_dependency 'rake', '~> 10.0'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: perx-rubocop
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Rui Baltazar
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-11-
|
11
|
+
date: 2019-11-29 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.77.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.77.0
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: rubocop-rails
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|