chefstyle 2.0.9 → 2.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: 02f6bfb5071459f0eca9733c7cfff85f5152fcfb7a2719dc3bb29a337f110e78
4
- data.tar.gz: 7ab00c86bf0ee04ba841d8c21a0e768b97ee3881ec1e2ffc3cf37f0e2974cbbc
3
+ metadata.gz: 3fd3b7ee2c2b897278e81858af450a48fa72bac1e64fdc60f09a4f419b3b5588
4
+ data.tar.gz: 7553f506631f741900f40872727ec2a0f6c3abfc8a0b1ba00947dd2c4546ce6b
5
5
  SHA512:
6
- metadata.gz: c57e11fe5a2d8e1b5e8abdf2a2b1c4109ee40ce73da1f1647dd42350c55ab6ff30292f55a11e50d57e5d5cd9ccade9ee015f03d7cccc0893793e69edd66b2ec5
7
- data.tar.gz: dbee5d8c1476bfa3baa3127add777358d67c2bc3ad6ec1142cfdb820529f61024d6b1dfa162e8178872a6b2ffd7a00ec4c1d07efbe7e10490967ab241462953c
6
+ metadata.gz: ab3cbc02ed9987b77d29206938e2dac4f1ce1e4c84cf60013b3dd2f3b998e7531cb935e91b972d865ba6ba2cb1d51c7116ac8abf7b74db9402dec088b721353c
7
+ data.tar.gz: a24689342db2bdeb3717e812314bffdd369690d68d94332abd885dd0ea108f7f96f3f9b47779c976938fc94788a5141621fe8a83912bb0665f6647bef9e9c5a0
data/config/chefstyle.yml CHANGED
@@ -9,6 +9,10 @@ AllCops:
9
9
  Bundler/DuplicatedGem:
10
10
  Enabled: false
11
11
 
12
+ Bundler/InsecureProtocolSource:
13
+ Enabled: true
14
+ AllowHttpProtocol: false
15
+
12
16
  #
13
17
  # Lint
14
18
  #
@@ -221,6 +221,8 @@ Lint/AmbiguousBlockAssociation:
221
221
  Enabled: false
222
222
  Lint/AmbiguousOperator:
223
223
  Enabled: false
224
+ Lint/AmbiguousOperatorPrecedence:
225
+ Enabled: false
224
226
  Lint/AmbiguousRange:
225
227
  Enabled: false
226
228
  Lint/AmbiguousRegexpLiteral:
@@ -307,10 +309,12 @@ Lint/IdentityComparison:
307
309
  Enabled: false
308
310
  Lint/ImplicitStringConcatenation:
309
311
  Enabled: false
310
- Lint/InheritException:
312
+ Lint/IncompatibleIoSelectWithFiberScheduler:
311
313
  Enabled: false
312
314
  Lint/IneffectiveAccessModifier:
313
315
  Enabled: false
316
+ Lint/InheritException:
317
+ Enabled: false
314
318
  Lint/InterpolationCheck:
315
319
  Enabled: false
316
320
  Lint/LambdaWithoutLiteralBlock:
@@ -383,6 +387,8 @@ Lint/RegexpAsCondition:
383
387
  Enabled: false
384
388
  Lint/RequireParentheses:
385
389
  Enabled: false
390
+ Lint/RequireRelativeSelfPath:
391
+ Enabled: false
386
392
  Lint/RescueException:
387
393
  Enabled: false
388
394
  Lint/RescueType:
@@ -701,6 +707,8 @@ Style/MethodCallWithArgsParentheses:
701
707
  Enabled: false
702
708
  Style/MultilineInPatternThen:
703
709
  Enabled: false
710
+ Style/NumberedParameters:
711
+ Enabled: false
704
712
  Style/RedundantAssignment:
705
713
  Enabled: false
706
714
  Style/RedundantFetchBlock:
@@ -773,6 +781,8 @@ Style/NonNilCheck:
773
781
  Enabled: false
774
782
  Style/Not:
775
783
  Enabled: false
784
+ Style/NumberedParametersLimit:
785
+ Enabled: false
776
786
  Style/NumericLiterals:
777
787
  Enabled: false
778
788
  Style/NumericLiteralPrefix:
@@ -853,6 +863,8 @@ Style/SafeNavigation:
853
863
  Enabled: false
854
864
  Style/Sample:
855
865
  Enabled: false
866
+ Style/SelectByRegexp:
867
+ Enabled: false
856
868
  Style/SelfAssignment:
857
869
  Enabled: false
858
870
  Style/Semicolon:
@@ -945,6 +957,8 @@ Style/ZeroLengthPredicate:
945
957
  Enabled: false
946
958
  Security/Eval:
947
959
  Enabled: false
960
+ Security/IoMethods:
961
+ Enabled: false
948
962
  Security/JSONLoad:
949
963
  Enabled: false
950
964
  Security/MarshalLoad:
data/config/upstream.yml CHANGED
@@ -130,7 +130,7 @@ AllCops:
130
130
  # What MRI version of the Ruby interpreter is the inspected code intended to
131
131
  # run on? (If there is more than one, set this to the lowest version.)
132
132
  # If a value is specified for TargetRubyVersion then it is used. Acceptable
133
- # values are specificed as a float (i.e. 3.0); the teeny version of Ruby
133
+ # values are specified as a float (i.e. 3.0); the teeny version of Ruby
134
134
  # should not be included. If the project specifies a Ruby version in the
135
135
  # .tool-versions or .ruby-version files, Gemfile or gems.rb file, RuboCop will
136
136
  # try to determine the desired version of Ruby by inspecting the
@@ -209,6 +209,7 @@ Bundler/InsecureProtocolSource:
209
209
  'https://rubygems.org' if possible, or 'http://rubygems.org' if not.
210
210
  Enabled: true
211
211
  VersionAdded: '0.50'
212
+ AllowHttpProtocol: true
212
213
  Include:
213
214
  - '**/*.gemfile'
214
215
  - '**/Gemfile'
@@ -957,7 +958,6 @@ Layout/LineLength:
957
958
  Enabled: true
958
959
  VersionAdded: '0.25'
959
960
  VersionChanged: '1.4'
960
- AutoCorrect: true
961
961
  Max: 120
962
962
  # To make it possible to copy or click on URIs in the code, we allow lines
963
963
  # containing a URI to be longer than Max.
@@ -1361,10 +1361,11 @@ Layout/SpaceInsideParens:
1361
1361
  StyleGuide: '#spaces-braces'
1362
1362
  Enabled: true
1363
1363
  VersionAdded: '0.49'
1364
- VersionChanged: '0.55'
1364
+ VersionChanged: '1.22'
1365
1365
  EnforcedStyle: no_space
1366
1366
  SupportedStyles:
1367
1367
  - space
1368
+ - compact
1368
1369
  - no_space
1369
1370
 
1370
1371
  Layout/SpaceInsidePercentLiteralDelimiters:
@@ -1448,6 +1449,13 @@ Lint/AmbiguousOperator:
1448
1449
  VersionAdded: '0.17'
1449
1450
  VersionChanged: '0.83'
1450
1451
 
1452
+ Lint/AmbiguousOperatorPrecedence:
1453
+ Description: >-
1454
+ Checks for expressions containing multiple binary operations with
1455
+ ambiguous precedence.
1456
+ Enabled: pending
1457
+ VersionAdded: '1.21'
1458
+
1451
1459
  Lint/AmbiguousRange:
1452
1460
  Description: Checks for ranges with ambiguous boundaries.
1453
1461
  Enabled: pending
@@ -1485,9 +1493,9 @@ Lint/BinaryOperatorWithIdenticalOperands:
1485
1493
  Lint/BooleanSymbol:
1486
1494
  Description: 'Check for `:true` and `:false` symbols.'
1487
1495
  Enabled: true
1488
- Safe: false
1496
+ SafeAutoCorrect: false
1489
1497
  VersionAdded: '0.50'
1490
- VersionChanged: '0.83'
1498
+ VersionChanged: '1.22'
1491
1499
 
1492
1500
  Lint/CircularArgumentReference:
1493
1501
  Description: "Default values in optional keyword arguments and optional ordinal arguments should not refer back to the name of the argument."
@@ -1771,6 +1779,11 @@ Lint/ImplicitStringConcatenation:
1771
1779
  Enabled: true
1772
1780
  VersionAdded: '0.36'
1773
1781
 
1782
+ Lint/IncompatibleIoSelectWithFiberScheduler:
1783
+ Description: 'Checks for `IO.select` that is incompatible with Fiber Scheduler.'
1784
+ Enabled: pending
1785
+ VersionAdded: '1.21'
1786
+
1774
1787
  Lint/IneffectiveAccessModifier:
1775
1788
  Description: >-
1776
1789
  Checks for attempts to use `private` or `protected` to set
@@ -2034,6 +2047,11 @@ Lint/RequireParentheses:
2034
2047
  Enabled: true
2035
2048
  VersionAdded: '0.18'
2036
2049
 
2050
+ Lint/RequireRelativeSelfPath:
2051
+ Description: 'Checks for uses a file requiring itself with `require_relative`.'
2052
+ Enabled: pending
2053
+ VersionAdded: '1.22'
2054
+
2037
2055
  Lint/RescueException:
2038
2056
  Description: 'Avoid rescuing the Exception class.'
2039
2057
  StyleGuide: '#no-blind-rescues'
@@ -2563,8 +2581,9 @@ Naming/HeredocDelimiterNaming:
2563
2581
 
2564
2582
  Naming/InclusiveLanguage:
2565
2583
  Description: 'Recommend the use of inclusive language instead of problematic terms.'
2566
- Enabled: pending
2584
+ Enabled: false
2567
2585
  VersionAdded: '1.18'
2586
+ VersionChanged: '1.21'
2568
2587
  CheckIdentifiers: true
2569
2588
  CheckConstants: true
2570
2589
  CheckVariables: true
@@ -2720,6 +2739,14 @@ Security/Eval:
2720
2739
  Enabled: true
2721
2740
  VersionAdded: '0.47'
2722
2741
 
2742
+ Security/IoMethods:
2743
+ Description: >-
2744
+ Checks for the first argument to `IO.read`, `IO.binread`, `IO.write`, `IO.binwrite`,
2745
+ `IO.foreach`, and `IO.readlines`.
2746
+ Enabled: pending
2747
+ Safe: false
2748
+ VersionAdded: '1.22'
2749
+
2723
2750
  Security/JSONLoad:
2724
2751
  Description: >-
2725
2752
  Prefer usage of `JSON.parse` over `JSON.load` due to potential
@@ -2796,8 +2823,9 @@ Style/AndOr:
2796
2823
  Description: 'Use &&/|| instead of and/or.'
2797
2824
  StyleGuide: '#no-and-or-or'
2798
2825
  Enabled: true
2826
+ SafeAutoCorrect: false
2799
2827
  VersionAdded: '0.9'
2800
- VersionChanged: '0.25'
2828
+ VersionChanged: '1.21'
2801
2829
  # Whether `and` and `or` are banned only in conditionals (conditionals)
2802
2830
  # or completely (always).
2803
2831
  EnforcedStyle: conditionals
@@ -2831,9 +2859,9 @@ Style/ArrayJoin:
2831
2859
  Style/AsciiComments:
2832
2860
  Description: 'Use only ascii symbols in comments.'
2833
2861
  StyleGuide: '#english-comments'
2834
- Enabled: true
2862
+ Enabled: false
2835
2863
  VersionAdded: '0.9'
2836
- VersionChanged: '0.52'
2864
+ VersionChanged: '1.21'
2837
2865
  AllowedChars:
2838
2866
  - ©
2839
2867
 
@@ -2995,7 +3023,7 @@ Style/CaseEquality:
2995
3023
  Enabled: true
2996
3024
  VersionAdded: '0.9'
2997
3025
  VersionChanged: '0.89'
2998
- # If AllowOnConstant is enabled, the cop will ignore violations when the receiver of
3026
+ # If `AllowOnConstant` option is enabled, the cop will ignore violations when the receiver of
2999
3027
  # the case equality operator is a constant.
3000
3028
  #
3001
3029
  # # bad
@@ -3690,7 +3718,7 @@ Style/InPatternThen:
3690
3718
  Style/InfiniteLoop:
3691
3719
  Description: >-
3692
3720
  Use Kernel#loop for infinite loops.
3693
- This cop is unsafe in the body may raise a `StopIteration` exception.
3721
+ This cop is unsafe if the body may raise a `StopIteration` exception.
3694
3722
  Safe: false
3695
3723
  StyleGuide: '#infinite-loop'
3696
3724
  Enabled: true
@@ -4116,6 +4144,21 @@ Style/Not:
4116
4144
  VersionAdded: '0.9'
4117
4145
  VersionChanged: '0.20'
4118
4146
 
4147
+ Style/NumberedParameters:
4148
+ Description: 'Restrict the usage of numbered parameters.'
4149
+ Enabled: pending
4150
+ VersionAdded: '1.22'
4151
+ EnforcedStyle: allow_single_line
4152
+ SupportedStyles:
4153
+ - allow_single_line
4154
+ - disallow
4155
+
4156
+ Style/NumberedParametersLimit:
4157
+ Description: 'Avoid excessive numbered params in a single block.'
4158
+ Enabled: pending
4159
+ VersionAdded: '1.22'
4160
+ Max: 1
4161
+
4119
4162
  Style/NumericLiteralPrefix:
4120
4163
  Description: 'Use smallcase prefixes for numeric literals.'
4121
4164
  StyleGuide: '#numeric-literal-prefixes'
@@ -4126,7 +4169,6 @@ Style/NumericLiteralPrefix:
4126
4169
  - zero_with_o
4127
4170
  - zero_only
4128
4171
 
4129
-
4130
4172
  Style/NumericLiterals:
4131
4173
  Description: >-
4132
4174
  Add underscores to large numeric literals to improve their
@@ -4447,6 +4489,8 @@ Style/RedundantSort:
4447
4489
  `max_by` instead of `sort_by...last`, etc.
4448
4490
  Enabled: true
4449
4491
  VersionAdded: '0.76'
4492
+ VersionChanged: '1.22'
4493
+ Safe: false
4450
4494
 
4451
4495
  Style/RedundantSortBy:
4452
4496
  Description: 'Use `sort` instead of `sort_by { |x| x }`.'
@@ -4527,6 +4571,12 @@ Style/Sample:
4527
4571
  Enabled: true
4528
4572
  VersionAdded: '0.30'
4529
4573
 
4574
+ Style/SelectByRegexp:
4575
+ Description: 'Prefer grep/grep_v to select/reject with a regexp match.'
4576
+ Enabled: pending
4577
+ SafeAutoCorrect: false
4578
+ VersionAdded: '1.22'
4579
+
4530
4580
  Style/SelfAssignment:
4531
4581
  Description: >-
4532
4582
  Checks for places where self-assignment shorthand should have
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
  module Chefstyle
3
- VERSION = "2.0.9"
4
- RUBOCOP_VERSION = "1.20.0"
3
+ VERSION = "2.1.0"
4
+ RUBOCOP_VERSION = "1.22.0"
5
5
  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: 2.0.9
4
+ version: 2.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: 2021-08-27 00:00:00.000000000 Z
11
+ date: 2021-09-30 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: 1.20.0
19
+ version: 1.22.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: 1.20.0
26
+ version: 1.22.0
27
27
  description:
28
28
  email:
29
29
  - oss@chef.io