house_style 2.0.2 → 2.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +19 -0
- data/features/rubocop.yml +15 -0
- data/house_style.gemspec +5 -5
- data/lib/generators/house_style/install_generator.rb +10 -2
- data/lib/generators/house_style/templates/features_rubocop.yml +3 -0
- data/lib/generators/house_style/templates/{rspec-rubocop.yml → rspec_rubocop.yml} +0 -0
- data/rails/rubocop.yml +4 -7
- data/rails/style.yml +0 -2
- data/rspec/rubocop.yml +6 -4
- data/ruby/configuration.yml +9 -3
- metadata +12 -12
- data/bin/console +0 -14
- data/bin/setup +0 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ce8222443b062e50feeb386f3d441f0f5e549bf2f461f457c27714f0cc0dad96
|
4
|
+
data.tar.gz: 6157b1653324717cdf7dc1edeca3a089d940ee701096657e66a1a35f3e7bde65
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 79765f7756680a6fbdf8983dad1855e8768ab2be58045111d9b31ed16f69b2285f61f1744325d26069bc2c55d814ab0031dc8bf9bb97a034c1568dc1a077689c
|
7
|
+
data.tar.gz: c7cd1db842e928fb54547daabb34f64544b20eb7f22cad1b5de43429b737d2cd511998b2d1c3ee5d0397bd328a43901caa9d32d74811324dde1644685d780321
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,24 @@
|
|
1
1
|
# CHANGELOG
|
2
2
|
|
3
|
+
## CURRENT
|
4
|
+
|
5
|
+
## 2.2.1
|
6
|
+
### Bug fixes
|
7
|
+
- Do not skip features/ directory in the gem when packaging.
|
8
|
+
|
9
|
+
## 2.2.0
|
10
|
+
### Bug fixes
|
11
|
+
- Install db_migrate.yml only if `db/migrate/` folder exists rather than just `db/` folder.
|
12
|
+
### Changes
|
13
|
+
- Rails: Move the AllCops to the Ruby one instead of repeating the same block. Disable Rails/SquishedSQLHeredocs and Rails/SkipsModelValidations.
|
14
|
+
- RSpec: Disable Spec/ContextWording, RSpec/NestedGroups, RSpec/DescribeClass and Style/BlockDelimiters.
|
15
|
+
### New features
|
16
|
+
- Add new configuration for feature tests inside `features/` folder.
|
17
|
+
|
18
|
+
## 2.1.0
|
19
|
+
- Enable NewCops by default
|
20
|
+
- Support Rubocop up to 1.22.x and latest extensions
|
21
|
+
|
3
22
|
## 2.0.2
|
4
23
|
### Bug fixes
|
5
24
|
- Exclude Guardfile from Ruby & Rails configurations
|
@@ -0,0 +1,15 @@
|
|
1
|
+
inherit_from: ../ruby/rubocop.yml
|
2
|
+
|
3
|
+
Layout/LineLength:
|
4
|
+
Enabled: false
|
5
|
+
Metrics/BlockLength:
|
6
|
+
Enabled: false
|
7
|
+
Metrics/ModuleLength:
|
8
|
+
Enabled: false
|
9
|
+
Style/BlockDelimiters:
|
10
|
+
Exclude:
|
11
|
+
- factories/**/*
|
12
|
+
Style/Documentation:
|
13
|
+
Enabled: false
|
14
|
+
Style/WordArray:
|
15
|
+
Enabled: false
|
data/house_style.gemspec
CHANGED
@@ -3,7 +3,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
3
3
|
|
4
4
|
Gem::Specification.new do |spec|
|
5
5
|
spec.name = 'house_style'
|
6
|
-
spec.version = '2.
|
6
|
+
spec.version = '2.2.1'
|
7
7
|
spec.authors = ['Altmetric', 'Scott Matthewman']
|
8
8
|
spec.email = ['engineering@altmetric.com', 'scott.matthewman@gmail.com']
|
9
9
|
|
@@ -12,14 +12,14 @@ Gem::Specification.new do |spec|
|
|
12
12
|
spec.homepage = 'https://github.com/altmetric/house_style'
|
13
13
|
spec.license = 'MIT'
|
14
14
|
|
15
|
-
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(
|
15
|
+
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(bin|.gitignore|)/}) }
|
16
16
|
spec.require_paths = ['lib']
|
17
17
|
|
18
|
-
spec.add_dependency 'rubocop', '>= 1.0', '< 1.
|
18
|
+
spec.add_dependency 'rubocop', '>= 1.0', '< 1.23'
|
19
19
|
spec.add_dependency 'rubocop-performance', '~> 1.11.3'
|
20
|
-
spec.add_dependency 'rubocop-rails', '~> 2.
|
20
|
+
spec.add_dependency 'rubocop-rails', '~> 2.12.3'
|
21
21
|
spec.add_dependency 'rubocop-rake', '< 1.0'
|
22
|
-
spec.add_dependency 'rubocop-rspec', '~> 2.
|
22
|
+
spec.add_dependency 'rubocop-rspec', '~> 2.5.0'
|
23
23
|
|
24
24
|
spec.add_development_dependency 'bundler', '~> 2.0'
|
25
25
|
spec.add_development_dependency 'rake', '~> 13.0'
|
@@ -12,17 +12,25 @@ module HouseStyle
|
|
12
12
|
end
|
13
13
|
|
14
14
|
def create_rspec_rubocop_yml
|
15
|
-
template '
|
15
|
+
template 'rspec_rubocop.yml', 'spec/.rubocop.yml'
|
16
16
|
end
|
17
17
|
|
18
18
|
def create_db_migrate_rubocop_yml
|
19
19
|
template 'db_migrate_rubocop.yml', 'db/migrate/.rubocop.yml' if Dir.exist?(db_path)
|
20
20
|
end
|
21
21
|
|
22
|
+
def create_features_rubocop_yml
|
23
|
+
template 'features_rubocop.yml', 'features/.rubocop.yml' if Dir.exist?(features_path)
|
24
|
+
end
|
25
|
+
|
22
26
|
private
|
23
27
|
|
24
28
|
def db_path
|
25
|
-
File.join(Rails.root, 'db')
|
29
|
+
File.join(Rails.root, 'db', 'migrate')
|
30
|
+
end
|
31
|
+
|
32
|
+
def features_path
|
33
|
+
File.join(Rails.root, 'features')
|
26
34
|
end
|
27
35
|
end
|
28
36
|
end
|
File without changes
|
data/rails/rubocop.yml
CHANGED
@@ -3,13 +3,6 @@ inherit_from:
|
|
3
3
|
- ./default_rules.yml
|
4
4
|
- ./style.yml
|
5
5
|
|
6
|
-
AllCops:
|
7
|
-
Exclude:
|
8
|
-
- bin/**/*
|
9
|
-
- vendor/**/*
|
10
|
-
- db/*schema.rb
|
11
|
-
- lib/tasks/cucumber.rake
|
12
|
-
- Guardfile
|
13
6
|
Rails:
|
14
7
|
Enabled: true
|
15
8
|
Rails/InverseOf:
|
@@ -21,5 +14,9 @@ Rails/EnvironmentVariableAccess:
|
|
21
14
|
AllowReads: true
|
22
15
|
Rails/ShortI18n:
|
23
16
|
Enabled: false
|
17
|
+
Rails/SquishedSQLHeredocs:
|
18
|
+
Enabled: false
|
19
|
+
Rails/SkipsModelValidations:
|
20
|
+
Enabled: false
|
24
21
|
|
25
22
|
require: rubocop-rails
|
data/rails/style.yml
CHANGED
data/rspec/rubocop.yml
CHANGED
@@ -14,8 +14,7 @@ Metrics/BlockLength:
|
|
14
14
|
Metrics/ModuleLength:
|
15
15
|
Enabled: false
|
16
16
|
RSpec/ContextWording:
|
17
|
-
|
18
|
-
- spec/support/shared_contexts/rake.rb
|
17
|
+
Enabled: false
|
19
18
|
RSpec/ExampleLength:
|
20
19
|
Enabled: false
|
21
20
|
RSpec/MultipleExpectations:
|
@@ -24,9 +23,12 @@ RSpec/MultipleMemoizedHelpers:
|
|
24
23
|
Max: 10
|
25
24
|
RSpec/NotToNot:
|
26
25
|
EnforcedStyle: to_not
|
26
|
+
RSpec/NestedGroups:
|
27
|
+
Enabled: false
|
28
|
+
RSpec/DescribeClass:
|
29
|
+
Enabled: false
|
27
30
|
Style/BlockDelimiters:
|
28
|
-
|
29
|
-
- spec/factories/**/*.rb
|
31
|
+
Enabled: false
|
30
32
|
Style/Documentation:
|
31
33
|
Enabled: false
|
32
34
|
Style/SymbolProc:
|
data/ruby/configuration.yml
CHANGED
@@ -3,11 +3,17 @@ AllCops:
|
|
3
3
|
DisplayStyleGuide: true
|
4
4
|
ExtraDetails: true
|
5
5
|
UseCache: true
|
6
|
+
NewCops: enable
|
6
7
|
|
7
8
|
Exclude:
|
8
|
-
-
|
9
|
-
-
|
10
|
-
-
|
9
|
+
- bin/**/*
|
10
|
+
- vendor/**/*
|
11
|
+
- Guardfile
|
12
|
+
- lib/tasks/cucumber.rake
|
13
|
+
- node_modules/**/*
|
14
|
+
- tmp/**/*
|
15
|
+
- db/*schema.rb
|
16
|
+
- config.ru
|
11
17
|
|
12
18
|
Gemspec/RequiredRubyVersion:
|
13
19
|
Enabled: false
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: house_style
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Altmetric
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2022-05-11 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rubocop
|
@@ -20,7 +20,7 @@ dependencies:
|
|
20
20
|
version: '1.0'
|
21
21
|
- - "<"
|
22
22
|
- !ruby/object:Gem::Version
|
23
|
-
version: '1.
|
23
|
+
version: '1.23'
|
24
24
|
type: :runtime
|
25
25
|
prerelease: false
|
26
26
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -30,7 +30,7 @@ dependencies:
|
|
30
30
|
version: '1.0'
|
31
31
|
- - "<"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '1.
|
33
|
+
version: '1.23'
|
34
34
|
- !ruby/object:Gem::Dependency
|
35
35
|
name: rubocop-performance
|
36
36
|
requirement: !ruby/object:Gem::Requirement
|
@@ -51,14 +51,14 @@ dependencies:
|
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: 2.
|
54
|
+
version: 2.12.3
|
55
55
|
type: :runtime
|
56
56
|
prerelease: false
|
57
57
|
version_requirements: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
59
|
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version: 2.
|
61
|
+
version: 2.12.3
|
62
62
|
- !ruby/object:Gem::Dependency
|
63
63
|
name: rubocop-rake
|
64
64
|
requirement: !ruby/object:Gem::Requirement
|
@@ -79,14 +79,14 @@ dependencies:
|
|
79
79
|
requirements:
|
80
80
|
- - "~>"
|
81
81
|
- !ruby/object:Gem::Version
|
82
|
-
version: 2.
|
82
|
+
version: 2.5.0
|
83
83
|
type: :runtime
|
84
84
|
prerelease: false
|
85
85
|
version_requirements: !ruby/object:Gem::Requirement
|
86
86
|
requirements:
|
87
87
|
- - "~>"
|
88
88
|
- !ruby/object:Gem::Version
|
89
|
-
version: 2.
|
89
|
+
version: 2.5.0
|
90
90
|
- !ruby/object:Gem::Dependency
|
91
91
|
name: bundler
|
92
92
|
requirement: !ruby/object:Gem::Requirement
|
@@ -135,12 +135,12 @@ files:
|
|
135
135
|
- LICENSE.txt
|
136
136
|
- README.md
|
137
137
|
- Rakefile
|
138
|
-
-
|
139
|
-
- bin/setup
|
138
|
+
- features/rubocop.yml
|
140
139
|
- house_style.gemspec
|
141
140
|
- lib/generators/house_style/install_generator.rb
|
142
141
|
- lib/generators/house_style/templates/db_migrate_rubocop.yml
|
143
|
-
- lib/generators/house_style/templates/
|
142
|
+
- lib/generators/house_style/templates/features_rubocop.yml
|
143
|
+
- lib/generators/house_style/templates/rspec_rubocop.yml
|
144
144
|
- lib/generators/house_style/templates/rubocop.yml
|
145
145
|
- performance/default_rules.yml
|
146
146
|
- performance/rubocop.yml
|
@@ -174,7 +174,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
174
174
|
- !ruby/object:Gem::Version
|
175
175
|
version: '0'
|
176
176
|
requirements: []
|
177
|
-
rubygems_version: 3.2.
|
177
|
+
rubygems_version: 3.2.33
|
178
178
|
signing_key:
|
179
179
|
specification_version: 4
|
180
180
|
summary: A centralised store of house style rules
|
data/bin/console
DELETED
@@ -1,14 +0,0 @@
|
|
1
|
-
#!/usr/bin/env ruby
|
2
|
-
|
3
|
-
require 'bundler/setup'
|
4
|
-
require 'house_style'
|
5
|
-
|
6
|
-
# You can add fixtures and/or initialization code here to make experimenting
|
7
|
-
# with your gem easier. You can also use a different console, if you like.
|
8
|
-
|
9
|
-
# (If you use this, don't forget to add pry to your Gemfile!)
|
10
|
-
# require 'pry'
|
11
|
-
# Pry.start
|
12
|
-
|
13
|
-
require 'irb'
|
14
|
-
IRB.start
|