rubocop-style-compact_nesting 0.1.0 → 0.1.2
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 +22 -0
- data/README.md +12 -2
- data/config/default.yml +7 -0
- data/lib/rubocop/style/compact_nesting/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 7efac5d3b9601cc72a98fe9efdcf0301828fe74cc0f1986c8edebf69245ce129
|
|
4
|
+
data.tar.gz: e9085acb97d10da319a190eb5c7ae52d2a506c859d474cbd3be06f7ae5d2be61
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b5f3be1af520eba26f0d8770d7e71317b8caf3cdcfc3bf27b772621468a6e407d6b4a8c80eb0a7949275ab7ebb6c65d82badf1522eb400f4a54ed02ae4d8fa72
|
|
7
|
+
data.tar.gz: db5c83002a520a8bcc007fbee25e9fdf9ec4a0910fffdd71b1a8423b112f8d88c782ed7cda2e22a4763db809deecc05671d521ba4fc243981d321b9b2a47ddc1
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,27 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.1.2] - 2026-06-01
|
|
4
|
+
|
|
5
|
+
### Changed
|
|
6
|
+
- README now ships with gem version, CI status, downloads, and license
|
|
7
|
+
badges.
|
|
8
|
+
|
|
9
|
+
### Added
|
|
10
|
+
- Regression test pinning the plugin's default config behaviour.
|
|
11
|
+
|
|
12
|
+
### Internal
|
|
13
|
+
- Ruby 4.0 (preview) added to the CI matrix as a non-blocking job.
|
|
14
|
+
- `CONTRIBUTING.md` documenting the dev loop, PR flow, and tag-driven
|
|
15
|
+
release process.
|
|
16
|
+
|
|
17
|
+
## [0.1.1] - 2026-06-01
|
|
18
|
+
|
|
19
|
+
### Changed
|
|
20
|
+
- Plugin default config now disables `Style/ClassAndModuleChildren`. That
|
|
21
|
+
cop enforces the opposite layout of `Style/CompactModuleNesting`, so the
|
|
22
|
+
two would always disagree. Users who want `Style/ClassAndModuleChildren`
|
|
23
|
+
can re-enable it explicitly in their own `.rubocop.yml`.
|
|
24
|
+
|
|
3
25
|
## [0.1.0] - 2026-06-01
|
|
4
26
|
|
|
5
27
|
### Added
|
data/README.md
CHANGED
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
# rubocop-style-compact_nesting
|
|
2
2
|
|
|
3
|
+
[](https://rubygems.org/gems/rubocop-style-compact_nesting)
|
|
4
|
+
[](https://github.com/ramongr/rubocop-style-compact_nesting/actions/workflows/ci.yml)
|
|
5
|
+
[](https://rubygems.org/gems/rubocop-style-compact_nesting)
|
|
6
|
+
[](LICENSE.txt)
|
|
7
|
+
|
|
3
8
|
A RuboCop plugin that enforces a hybrid module/class nesting style:
|
|
4
9
|
|
|
5
10
|
- All namespace segments are **collapsed onto a single `module` line** using
|
|
@@ -85,10 +90,15 @@ gem 'rubocop-style-compact_nesting', require: false
|
|
|
85
90
|
# .rubocop.yml
|
|
86
91
|
plugins:
|
|
87
92
|
- rubocop-style-compact_nesting
|
|
93
|
+
```
|
|
88
94
|
|
|
89
|
-
|
|
95
|
+
The plugin disables `Style/ClassAndModuleChildren` by default because that
|
|
96
|
+
cop enforces the opposite layout. If you want it back, re-enable it in
|
|
97
|
+
your own config:
|
|
98
|
+
|
|
99
|
+
```yaml
|
|
90
100
|
Style/ClassAndModuleChildren:
|
|
91
|
-
Enabled:
|
|
101
|
+
Enabled: true
|
|
92
102
|
```
|
|
93
103
|
|
|
94
104
|
Requires RuboCop `>= 1.72` and Ruby `>= 3.1`.
|
data/config/default.yml
CHANGED
|
@@ -7,3 +7,10 @@ Style/CompactModuleNesting:
|
|
|
7
7
|
VersionAdded: '0.1'
|
|
8
8
|
SafeAutoCorrect: true
|
|
9
9
|
StyleGuide: ~
|
|
10
|
+
|
|
11
|
+
# Style/ClassAndModuleChildren expects the opposite of what
|
|
12
|
+
# Style/CompactModuleNesting enforces. Disable it by default to avoid the
|
|
13
|
+
# two cops fighting over the same code. Users who want it can re-enable
|
|
14
|
+
# it in their own .rubocop.yml.
|
|
15
|
+
Style/ClassAndModuleChildren:
|
|
16
|
+
Enabled: false
|