nonstandard 0.1.2 → 0.1.4
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 -1
- data/Gemfile.lock +28 -29
- data/README.md +23 -6
- data/lib/nonstandard/version.rb +1 -1
- data/{default.yml → rails.yml} +8 -17
- data/rswag.yml +30 -0
- data/ruby.yml +24 -0
- metadata +6 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7d41ece812b796042758cdd10fdae8a74865973a473e27074173f8ce594d8714
|
4
|
+
data.tar.gz: b5c5f3a67da690480c18b1e2db4e1a260956df1b13a1195da51a9aa7571e711d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7cd48eea60fa0d9179d13ab93f120086d298a2b478f531b82ea40e6e01e5530a72d8c3d4313fdeb9901b031e040dfd5e5b1dcbf24d8831ea45021e0f2d170fd3
|
7
|
+
data.tar.gz: b784fda0bbe30160d79cf91d21566ae59bdc33343f70965a52eecfed956a7b4d757a6279a687b45af2cd0f2e749ee7399671cb3eb6489a0d6cf7942f125fa820
|
data/CHANGELOG.md
CHANGED
@@ -1,7 +1,14 @@
|
|
1
1
|
# CHANGELOG
|
2
2
|
|
3
3
|
## main (unreleased)
|
4
|
-
|
4
|
+
|
5
|
+
## 0.1.4 (2022-08-16)
|
6
|
+
- Update Layout/LineLength language for AllowedPatterns
|
7
|
+
|
8
|
+
## 0.1.3 (2021-11-06)
|
9
|
+
- Split rules into ruby/rails/rswag(rspec) rules
|
10
|
+
- Add exclusion for annotate_models comments
|
11
|
+
- Add exclusion for spec variables ending with []
|
5
12
|
|
6
13
|
## 0.1.2 (2021-06-11)
|
7
14
|
- Improvement: Disable AbcSize/BlockLength/MethodLength
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
nonstandard (0.1.
|
4
|
+
nonstandard (0.1.4)
|
5
5
|
rubocop
|
6
6
|
rubocop-faker
|
7
7
|
rubocop-performance
|
@@ -12,58 +12,57 @@ PATH
|
|
12
12
|
GEM
|
13
13
|
remote: https://rubygems.org/
|
14
14
|
specs:
|
15
|
-
activesupport (
|
15
|
+
activesupport (7.0.3.1)
|
16
16
|
concurrent-ruby (~> 1.0, >= 1.0.2)
|
17
17
|
i18n (>= 1.6, < 2)
|
18
18
|
minitest (>= 5.1)
|
19
19
|
tzinfo (~> 2.0)
|
20
|
-
zeitwerk (~> 2.3)
|
21
20
|
ast (2.4.2)
|
22
|
-
concurrent-ruby (1.1.
|
23
|
-
faker (2.
|
24
|
-
i18n (>= 1.
|
25
|
-
i18n (1.
|
21
|
+
concurrent-ruby (1.1.10)
|
22
|
+
faker (2.22.0)
|
23
|
+
i18n (>= 1.8.11, < 2)
|
24
|
+
i18n (1.12.0)
|
26
25
|
concurrent-ruby (~> 1.0)
|
27
|
-
|
28
|
-
|
29
|
-
|
26
|
+
json (2.6.2)
|
27
|
+
minitest (5.16.2)
|
28
|
+
parallel (1.22.1)
|
29
|
+
parser (3.1.2.1)
|
30
30
|
ast (~> 2.4.1)
|
31
|
-
rack (2.2.
|
32
|
-
rainbow (3.
|
31
|
+
rack (2.2.4)
|
32
|
+
rainbow (3.1.1)
|
33
33
|
rake (13.0.3)
|
34
|
-
regexp_parser (2.
|
34
|
+
regexp_parser (2.5.0)
|
35
35
|
rexml (3.2.5)
|
36
|
-
rubocop (1.
|
36
|
+
rubocop (1.35.0)
|
37
|
+
json (~> 2.3)
|
37
38
|
parallel (~> 1.10)
|
38
|
-
parser (>= 3.
|
39
|
+
parser (>= 3.1.2.1)
|
39
40
|
rainbow (>= 2.2.2, < 4.0)
|
40
41
|
regexp_parser (>= 1.8, < 3.0)
|
41
|
-
rexml
|
42
|
-
rubocop-ast (>= 1.
|
42
|
+
rexml (>= 3.2.5, < 4.0)
|
43
|
+
rubocop-ast (>= 1.20.1, < 2.0)
|
43
44
|
ruby-progressbar (~> 1.7)
|
44
45
|
unicode-display_width (>= 1.4.0, < 3.0)
|
45
|
-
rubocop-ast (1.
|
46
|
-
parser (>= 3.
|
46
|
+
rubocop-ast (1.21.0)
|
47
|
+
parser (>= 3.1.1.0)
|
47
48
|
rubocop-faker (1.1.0)
|
48
49
|
faker (>= 2.12.0)
|
49
50
|
rubocop (>= 0.82.0)
|
50
|
-
rubocop-performance (1.
|
51
|
+
rubocop-performance (1.14.3)
|
51
52
|
rubocop (>= 1.7.0, < 2.0)
|
52
53
|
rubocop-ast (>= 0.4.0)
|
53
|
-
rubocop-rails (2.
|
54
|
+
rubocop-rails (2.15.2)
|
54
55
|
activesupport (>= 4.2.0)
|
55
56
|
rack (>= 1.1)
|
56
57
|
rubocop (>= 1.7.0, < 2.0)
|
57
|
-
rubocop-rake (0.
|
58
|
-
rubocop
|
59
|
-
rubocop-rspec (2.4.0)
|
58
|
+
rubocop-rake (0.6.0)
|
60
59
|
rubocop (~> 1.0)
|
61
|
-
|
60
|
+
rubocop-rspec (2.12.1)
|
61
|
+
rubocop (~> 1.31)
|
62
62
|
ruby-progressbar (1.11.0)
|
63
|
-
tzinfo (2.0.
|
63
|
+
tzinfo (2.0.5)
|
64
64
|
concurrent-ruby (~> 1.0)
|
65
|
-
unicode-display_width (2.
|
66
|
-
zeitwerk (2.4.2)
|
65
|
+
unicode-display_width (2.2.0)
|
67
66
|
|
68
67
|
PLATFORMS
|
69
68
|
arm64-darwin-20
|
@@ -74,4 +73,4 @@ DEPENDENCIES
|
|
74
73
|
rake (~> 13.0)
|
75
74
|
|
76
75
|
BUNDLED WITH
|
77
|
-
2.2.
|
76
|
+
2.2.30
|
data/README.md
CHANGED
@@ -21,8 +21,12 @@ end
|
|
21
21
|
Add this to your project `.rubocop.yml` file
|
22
22
|
|
23
23
|
```ruby
|
24
|
+
# Include one or more of the configurations below
|
24
25
|
inherit_gem:
|
25
|
-
nonstandard:
|
26
|
+
nonstandard:
|
27
|
+
- ruby.yml # Vanilla ruby/rubocop/performance
|
28
|
+
- rails.yml # Rails
|
29
|
+
- rswag.yml # RSpec/rswag integration
|
26
30
|
```
|
27
31
|
|
28
32
|
And then execute:
|
@@ -54,13 +58,26 @@ If you have access to publish the gem on rubygems:
|
|
54
58
|
|
55
59
|
1. Update the `version.rb` file as appropriate
|
56
60
|
1. `bundle` if any dependencies have changed
|
57
|
-
1. Commit all changes
|
58
61
|
1. Update the `CHANGELOG.md`
|
59
|
-
1.
|
60
|
-
|
61
|
-
|
62
|
-
|
62
|
+
1. Commit all changes & push to repo
|
63
|
+
1. Merge version branch into main
|
64
|
+
1. Tag the release on main
|
65
|
+
1. Publish to rubygems
|
63
66
|
|
67
|
+
Tagging the release:
|
68
|
+
|
69
|
+
```sh
|
70
|
+
git tag -a <version>
|
71
|
+
git push origin <version>
|
72
|
+
```
|
73
|
+
|
74
|
+
Publishing to rubygems:
|
75
|
+
|
76
|
+
```sh
|
77
|
+
rake build
|
78
|
+
cd pkg
|
79
|
+
gem push nonstandard.<version_number>.gem
|
80
|
+
```
|
64
81
|
|
65
82
|
## Contributing
|
66
83
|
|
data/lib/nonstandard/version.rb
CHANGED
data/{default.yml → rails.yml}
RENAMED
@@ -1,40 +1,31 @@
|
|
1
1
|
---
|
2
|
-
#
|
2
|
+
# https://github.com/rubocop-hq/rubocop/blob/master/config/default.yml
|
3
3
|
require:
|
4
|
-
- rubocop-faker
|
5
|
-
- rubocop-performance
|
6
4
|
- rubocop-rails
|
7
|
-
|
8
|
-
|
5
|
+
|
6
|
+
inherit_mode:
|
7
|
+
merge:
|
8
|
+
- Exclude
|
9
9
|
|
10
10
|
AllCops:
|
11
|
+
NewCops: enable
|
11
12
|
Exclude:
|
12
|
-
- 'bin/**/*'
|
13
|
-
- 'db/**/*'
|
14
13
|
- 'lib/tasks/*'
|
15
|
-
- 'Rakefile'
|
16
|
-
- '*.gemspec'
|
17
14
|
- '**/node_modules/**/*'
|
18
15
|
- 'vendor/**/*'
|
19
16
|
|
20
17
|
Layout/LineLength:
|
21
18
|
Exclude:
|
22
19
|
- config/routes.rb
|
20
|
+
AllowedPatterns:
|
21
|
+
- '\A# '
|
23
22
|
|
24
23
|
Metrics/AbcSize:
|
25
24
|
Enabled: false
|
26
25
|
|
27
|
-
Metrics/BlockLength:
|
28
|
-
Enabled: false
|
29
|
-
|
30
|
-
Metrics/MethodLength:
|
31
|
-
Enabled: false
|
32
|
-
|
33
26
|
Style/Documentation:
|
34
27
|
Exclude:
|
35
28
|
- app/controllers/**/*
|
36
29
|
- app/helpers/application_helper.rb
|
37
30
|
- app/models/application_record.rb
|
38
31
|
- config/application.rb
|
39
|
-
- spec/**/*
|
40
|
-
- test/**/*
|
data/rswag.yml
ADDED
@@ -0,0 +1,30 @@
|
|
1
|
+
---
|
2
|
+
# https://github.com/rubocop-hq/rubocop/blob/master/config/default.yml
|
3
|
+
require:
|
4
|
+
- rubocop-rspec
|
5
|
+
|
6
|
+
inherit_mode:
|
7
|
+
merge:
|
8
|
+
- Exclude
|
9
|
+
|
10
|
+
AllCops:
|
11
|
+
NewCops: enable
|
12
|
+
|
13
|
+
Layout/LineLength:
|
14
|
+
Exclude:
|
15
|
+
- spec/swagger_helper.rb
|
16
|
+
|
17
|
+
RSpec/EmptyExampleGroup:
|
18
|
+
Exclude:
|
19
|
+
- spec/requests/**/*
|
20
|
+
|
21
|
+
RSpec/VariableName:
|
22
|
+
IgnoredPatterns:
|
23
|
+
- ^Authorization
|
24
|
+
- .*\[\]
|
25
|
+
- .*\[(.*)?\]
|
26
|
+
|
27
|
+
Style/Documentation:
|
28
|
+
Exclude:
|
29
|
+
- spec/**/*
|
30
|
+
- test/**/*
|
data/ruby.yml
ADDED
@@ -0,0 +1,24 @@
|
|
1
|
+
---
|
2
|
+
# https://github.com/rubocop-hq/rubocop/blob/master/config/default.yml
|
3
|
+
require:
|
4
|
+
- rubocop-performance
|
5
|
+
- rubocop-rake
|
6
|
+
|
7
|
+
inherit_mode:
|
8
|
+
merge:
|
9
|
+
- Exclude
|
10
|
+
|
11
|
+
AllCops:
|
12
|
+
NewCops: enable
|
13
|
+
Exclude:
|
14
|
+
- 'Rakefile'
|
15
|
+
- '*.gemspec'
|
16
|
+
|
17
|
+
Metrics/AbcSize:
|
18
|
+
Enabled: false
|
19
|
+
|
20
|
+
Metrics/BlockLength:
|
21
|
+
Enabled: false
|
22
|
+
|
23
|
+
Metrics/MethodLength:
|
24
|
+
Enabled: false
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: nonstandard
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jay Dorsey
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2023-08-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rubocop
|
@@ -111,10 +111,12 @@ files:
|
|
111
111
|
- Rakefile
|
112
112
|
- bin/console
|
113
113
|
- bin/setup
|
114
|
-
- default.yml
|
115
114
|
- lib/nonstandard.rb
|
116
115
|
- lib/nonstandard/version.rb
|
117
116
|
- nonstandard.gemspec
|
117
|
+
- rails.yml
|
118
|
+
- rswag.yml
|
119
|
+
- ruby.yml
|
118
120
|
homepage: https://github.com/jaybocop/nonstandard
|
119
121
|
licenses:
|
120
122
|
- MIT
|
@@ -138,7 +140,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
138
140
|
- !ruby/object:Gem::Version
|
139
141
|
version: '0'
|
140
142
|
requirements: []
|
141
|
-
rubygems_version: 3.
|
143
|
+
rubygems_version: 3.4.13
|
142
144
|
signing_key:
|
143
145
|
specification_version: 4
|
144
146
|
summary: Opinionated Style Guide
|