chefstyle 1.0.5 → 1.1.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: eeae88f92a024d9fcc4807ee65df12a7362fd72c31d058c3ac912f3ddc8002b3
4
- data.tar.gz: 386d1d16c8dc7ff06fe434fa0199711a1931f06c674361deb73fb0f627070673
3
+ metadata.gz: cb8e8694ac330f16fbed4c272f4ea96ecc82e5ea0f4e5cb86d67afccd89dd4e9
4
+ data.tar.gz: 1226349965ce1702235ee02901ced43ea2f96f9026fd41d40fcd16b34d01ed89
5
5
  SHA512:
6
- metadata.gz: 3acfad2f00e590e688415528442b541b9eff3cf1c3da9ee9b4cb0dedc22ef42f687fffcf1093ee0d650b396d06258eb9e499eb8a17bf78c921a7ca7fb598704c
7
- data.tar.gz: 7c496c1d5bb771b872e6e36c5d632c135faf9cddb4fdb8dd015a56dcc28083f6c1c3bc69bd4015f2da39dae08dee846b05fb75be228a8dd5cc2e832a9bbbe0b6
6
+ metadata.gz: 3805bdeb602027ca973b45838837039c4f8f41742495755df414bc1b9541b6e81e2e9dcb6ce8ff8857dd1c1080b7e6d131da0624b8ca883082b599e3244d5bd6
7
+ data.tar.gz: e2c280aa7ad8d1779ada9549ccf89e5e6bd700b5c7a1a164404d47ea23609db213ef4ec61bdfdfe88dfe7ccec653698d3cdaa3d7e65c4befd60ea5f63aae68af
@@ -628,3 +628,7 @@ Style/Alias:
628
628
  # anyone else's time either.
629
629
  Style/CommentedKeyword:
630
630
  Enabled: false
631
+
632
+ # make sure we catch this Ruby 3.0 breaking change now
633
+ Lint/DeprecatedOpenSSLConstant:
634
+ Enabled: true
@@ -215,6 +215,8 @@ Lint/Debugger:
215
215
  Enabled: false
216
216
  Lint/DeprecatedClassMethods:
217
217
  Enabled: false
218
+ Lint/DeprecatedOpenSSLConstant:
219
+ Enabled: false
218
220
  Lint/DisjunctiveAssignmentInConstructor:
219
221
  Enabled: false
220
222
  Lint/DuplicateCaseCondition:
@@ -263,6 +265,8 @@ Lint/Loop:
263
265
  Enabled: false
264
266
  Lint/MissingCopEnableDirective:
265
267
  Enabled: false
268
+ Lint/MixedRegexpCaptureTypes:
269
+ Enabled: false
266
270
  Lint/MultipleComparison:
267
271
  Enabled: false
268
272
  Lint/NestedMethodDefinition:
@@ -667,6 +671,10 @@ Style/RedundantParentheses:
667
671
  Enabled: false
668
672
  Style/RedundantPercentQ:
669
673
  Enabled: false
674
+ Style/RedundantRegexpCharacterClass:
675
+ Enabled: false
676
+ Style/RedundantRegexpEscape:
677
+ Enabled: false
670
678
  Style/RedundantReturn:
671
679
  Enabled: false
672
680
  Style/RedundantSelf:
@@ -153,12 +153,13 @@ Bundler/GemComment:
153
153
  Description: 'Add a comment describing each gem.'
154
154
  Enabled: false
155
155
  VersionAdded: '0.59'
156
- VersionChanged: '0.77'
156
+ VersionChanged: '0.85'
157
157
  Include:
158
158
  - '**/*.gemfile'
159
159
  - '**/Gemfile'
160
160
  - '**/gems.rb'
161
161
  IgnoredGems: []
162
+ OnlyFor: []
162
163
 
163
164
  Bundler/InsecureProtocolSource:
164
165
  Description: >-
@@ -468,6 +469,13 @@ Layout/EmptyLinesAroundAttributeAccessor:
468
469
  StyleGuide: '#empty-lines-around-attribute-accessor'
469
470
  Enabled: pending
470
471
  VersionAdded: '0.83'
472
+ VersionChanged: '0.84'
473
+ AllowAliasSyntax: true
474
+ AllowedMethods:
475
+ - alias_method
476
+ - public
477
+ - protected
478
+ - private
471
479
 
472
480
  Layout/EmptyLinesAroundBeginBody:
473
481
  Description: "Keeps track of empty lines around begin-end bodies."
@@ -783,13 +791,7 @@ Layout/HeredocIndentation:
783
791
  StyleGuide: '#squiggly-heredocs'
784
792
  Enabled: true
785
793
  VersionAdded: '0.49'
786
- VersionChanged: '0.77'
787
- EnforcedStyle: squiggly
788
- SupportedStyles:
789
- - squiggly
790
- - active_support
791
- - powerpack
792
- - unindent
794
+ VersionChanged: '0.85'
793
795
 
794
796
  Layout/IndentationConsistency:
795
797
  Description: 'Keep indentation straight.'
@@ -857,13 +859,13 @@ Layout/LeadingEmptyLines:
857
859
  VersionChanged: '0.77'
858
860
 
859
861
  Layout/LineLength:
860
- Description: 'Limit lines to 80 characters.'
861
- StyleGuide: '#80-character-limits'
862
+ Description: 'Checks that line length does not exceed the configured limit.'
863
+ StyleGuide: '#max-line-length'
862
864
  Enabled: true
863
865
  VersionAdded: '0.25'
864
- VersionChanged: '0.78'
866
+ VersionChanged: '0.84'
865
867
  AutoCorrect: false
866
- Max: 80
868
+ Max: 120
867
869
  # To make it possible to copy or click on URIs in the code, we allow lines
868
870
  # containing a URI to be longer than Max.
869
871
  AllowHeredoc: true
@@ -1370,6 +1372,11 @@ Lint/DeprecatedClassMethods:
1370
1372
  Enabled: true
1371
1373
  VersionAdded: '0.19'
1372
1374
 
1375
+ Lint/DeprecatedOpenSSLConstant:
1376
+ Description: "Don't use algorithm constants for `OpenSSL::Cipher` and `OpenSSL::Digest`."
1377
+ Enabled: pending
1378
+ VersionAdded: '0.84'
1379
+
1373
1380
  Lint/DisjunctiveAssignmentInConstructor:
1374
1381
  Description: 'In constructor, plain assignment is preferred over disjunctive.'
1375
1382
  Enabled: true
@@ -1526,6 +1533,11 @@ Lint/MissingCopEnableDirective:
1526
1533
  # .inf for any size
1527
1534
  MaximumRangeSize: .inf
1528
1535
 
1536
+ Lint/MixedRegexpCaptureTypes:
1537
+ Description: 'Do not mix named captures and numbered captures in a Regexp literal.'
1538
+ Enabled: pending
1539
+ VersionAdded: '0.85'
1540
+
1529
1541
  Lint/MultipleComparison:
1530
1542
  Description: "Use `&&` operator to compare multiple values."
1531
1543
  Enabled: true
@@ -1999,6 +2011,11 @@ Naming/ClassAndModuleCamelCase:
1999
2011
  StyleGuide: '#camelcase-classes'
2000
2012
  Enabled: true
2001
2013
  VersionAdded: '0.50'
2014
+ VersionChanged: '0.85'
2015
+ # Allowed class/module names can be specified here.
2016
+ # These can be full or part of the name.
2017
+ AllowedNames:
2018
+ - module_parent
2002
2019
 
2003
2020
  Naming/ConstantName:
2004
2021
  Description: 'Constants should use SCREAMING_SNAKE_CASE.'
@@ -2019,6 +2036,10 @@ Naming/FileName:
2019
2036
  # It further expects it to be nested inside modules which match the names
2020
2037
  # of subdirectories in its path.
2021
2038
  ExpectMatchingDefinition: false
2039
+ # When `false`, changes the behavior of ExpectMatchingDefinition to match only
2040
+ # whether each source file's class or module name matches the file name --
2041
+ # not whether the nested module hierarchy matches the subdirectory path.
2042
+ CheckDefinitionPathHierarchy: true
2022
2043
  # If non-`nil`, expect all source file names to match the following regex.
2023
2044
  # Only the file name itself is matched, not the entire file path.
2024
2045
  # Use anchors as necessary if you want to match the entire name rather than
@@ -2210,7 +2231,7 @@ Security/JSONLoad:
2210
2231
  Description: >-
2211
2232
  Prefer usage of `JSON.parse` over `JSON.load` due to potential
2212
2233
  security issues. See reference for more information.
2213
- Reference: 'https://ruby-doc.org/stdlib-2.3.0/libdoc/json/rdoc/JSON.html#method-i-load'
2234
+ Reference: 'https://ruby-doc.org/stdlib-2.7.0/libdoc/json/rdoc/JSON.html#method-i-load'
2214
2235
  Enabled: true
2215
2236
  VersionAdded: '0.43'
2216
2237
  VersionChanged: '0.44'
@@ -2223,7 +2244,7 @@ Security/MarshalLoad:
2223
2244
  Description: >-
2224
2245
  Avoid using of `Marshal.load` or `Marshal.restore` due to potential
2225
2246
  security issues. See reference for more information.
2226
- Reference: 'https://ruby-doc.org/core-2.3.3/Marshal.html#module-Marshal-label-Security+considerations'
2247
+ Reference: 'https://ruby-doc.org/core-2.7.0/Marshal.html#module-Marshal-label-Security+considerations'
2227
2248
  Enabled: true
2228
2249
  VersionAdded: '0.47'
2229
2250
 
@@ -2237,7 +2258,7 @@ Security/YAMLLoad:
2237
2258
  Description: >-
2238
2259
  Prefer usage of `YAML.safe_load` over `YAML.load` due to potential
2239
2260
  security issues. See reference for more information.
2240
- Reference: 'https://ruby-doc.org/stdlib-2.3.3/libdoc/yaml/rdoc/YAML.html#module-YAML-label-Security'
2261
+ Reference: 'https://ruby-doc.org/stdlib-2.7.0/libdoc/yaml/rdoc/YAML.html#module-YAML-label-Security'
2241
2262
  Enabled: true
2242
2263
  VersionAdded: '0.47'
2243
2264
  SafeAutoCorrect: false
@@ -2274,7 +2295,7 @@ Style/AndOr:
2274
2295
  VersionChanged: '0.25'
2275
2296
  # Whether `and` and `or` are banned only in conditionals (conditionals)
2276
2297
  # or completely (always).
2277
- EnforcedStyle: always
2298
+ EnforcedStyle: conditionals
2278
2299
  SupportedStyles:
2279
2300
  - always
2280
2301
  - conditionals
@@ -2694,6 +2715,11 @@ Style/DoubleNegation:
2694
2715
  StyleGuide: '#no-bang-bang'
2695
2716
  Enabled: true
2696
2717
  VersionAdded: '0.19'
2718
+ VersionChanged: '0.84'
2719
+ EnforcedStyle: allowed_in_returns
2720
+ SupportedStyles:
2721
+ - allowed_in_returns
2722
+ - forbidden
2697
2723
 
2698
2724
  Style/EachForSimpleLoop:
2699
2725
  Description: >-
@@ -2857,8 +2883,7 @@ Style/FrozenStringLiteralComment:
2857
2883
  SupportedStyles:
2858
2884
  # `always` will always add the frozen string literal comment to a file
2859
2885
  # regardless of the Ruby version or if `freeze` or `<<` are called on a
2860
- # string literal. If you run code against multiple versions of Ruby, it is
2861
- # possible that this will create errors in Ruby 2.3.0+.
2886
+ # string literal. It is possible that this will create errors.
2862
2887
  - always
2863
2888
  # `always_true` will add the frozen string literal comment to a file,
2864
2889
  # similarly to the `always` style, but will also change any disabled
@@ -3593,6 +3618,16 @@ Style/RedundantPercentQ:
3593
3618
  Enabled: true
3594
3619
  VersionAdded: '0.76'
3595
3620
 
3621
+ Style/RedundantRegexpCharacterClass:
3622
+ Description: 'Checks for unnecessary single-element Regexp character classes.'
3623
+ Enabled: pending
3624
+ VersionAdded: '0.85'
3625
+
3626
+ Style/RedundantRegexpEscape:
3627
+ Description: 'Checks for redundant escapes in Regexps.'
3628
+ Enabled: pending
3629
+ VersionAdded: '0.85'
3630
+
3596
3631
  Style/RedundantReturn:
3597
3632
  Description: "Don't use return where it's not required."
3598
3633
  StyleGuide: '#no-explicit-return'
@@ -1,4 +1,4 @@
1
1
  module Chefstyle
2
- VERSION = "1.0.5".freeze
3
- RUBOCOP_VERSION = "0.83.0".freeze
2
+ VERSION = "1.1.0".freeze
3
+ RUBOCOP_VERSION = "0.85.0".freeze
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chefstyle
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.5
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chef Software, Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-05-11 00:00:00.000000000 Z
11
+ date: 2020-06-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -58,14 +58,14 @@ dependencies:
58
58
  requirements:
59
59
  - - '='
60
60
  - !ruby/object:Gem::Version
61
- version: 0.83.0
61
+ version: 0.85.0
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - '='
67
67
  - !ruby/object:Gem::Version
68
- version: 0.83.0
68
+ version: 0.85.0
69
69
  description:
70
70
  email:
71
71
  - oss@chef.io