puppet-syntax 4.0.0 → 4.0.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 680101f8a3cfb9d6c9c389e8c89f6514107f45ea6a20d067ca82724613ba47de
4
- data.tar.gz: 89685e36048969d15ef866c21637be9c41fe89fc71ad3e05298399f0b7192622
3
+ metadata.gz: 00b51658a2b442427a7acac7c712fb3188d90a66c3d328c5d719b2034b11ad3c
4
+ data.tar.gz: 33d7cea4918830fd06b91ce02feab1617eaf50a5554cec8d28e59deaff836cd5
5
5
  SHA512:
6
- metadata.gz: a4b33477972e17a5fd5274bf5767a6ce310a3381359404b1d060f0cf63a7507efd8f4896bf52aad1758f392a7618f64eb0dc30a0b5607406d7c5e7375ab23133
7
- data.tar.gz: 5495e81fe81b45bf9e99579320407d9e64cc70fb14cba686e52ad87439feb87a708d1b6230c50e5eafff9afcce3fd620dc57e403628776af4bb06e3404bf6b74
6
+ metadata.gz: daf199345270be08621d083a76ce169a089dee282a74ebc6de9475c89c36dbef95da3ccf9aac8e4121c267c3d079064e1d0de6f7701a74a4d4d9132b9bb1da72
7
+ data.tar.gz: 395e92778f90d03e941bf9cd67957cf65fc7ce47cac3816a951f9752e569f6056600a3fa3f42944b086d6e8256ad2596af2bf534f7f3e59fb0d8925f4ba36b3f
data/.rubocop_todo.yml CHANGED
@@ -1,6 +1,6 @@
1
1
  # This configuration was generated by
2
2
  # `rubocop --auto-gen-config`
3
- # on 2024-02-07 19:46:27 UTC using RuboCop version 1.60.2.
3
+ # on 2024-03-08 12:59:05 UTC using RuboCop version 1.61.0.
4
4
  # The point is for the user to remove these configuration records
5
5
  # one by one as the offenses are removed from the code base.
6
6
  # Note that changes in the inspected code, or installation of new
@@ -31,6 +31,7 @@ Lint/SuppressedException:
31
31
 
32
32
  # Offense count: 1
33
33
  # This cop supports unsafe autocorrection (--autocorrect-all).
34
+ # Configuration parameters: AutoCorrect.
34
35
  Lint/UselessAssignment:
35
36
  Exclude:
36
37
  - 'lib/puppet-syntax/templates.rb'
@@ -73,7 +74,7 @@ RSpec/DescribeClass:
73
74
 
74
75
  # Offense count: 19
75
76
  # This cop supports unsafe autocorrection (--autocorrect-all).
76
- # Configuration parameters: SkipBlocks, EnforcedStyle.
77
+ # Configuration parameters: SkipBlocks, EnforcedStyle, OnlyStaticConstants.
77
78
  # SupportedStyles: described_class, explicit
78
79
  RSpec/DescribedClass:
79
80
  Exclude:
@@ -139,13 +140,12 @@ Rake/Desc:
139
140
  Exclude:
140
141
  - 'Rakefile'
141
142
 
142
- # Offense count: 2
143
+ # Offense count: 1
143
144
  # This cop supports unsafe autocorrection (--autocorrect-all).
144
145
  # Configuration parameters: EnforcedStyle.
145
146
  # SupportedStyles: always, conditionals
146
147
  Style/AndOr:
147
148
  Exclude:
148
- - 'lib/puppet-syntax/manifests.rb'
149
149
  - 'lib/puppet-syntax/templates.rb'
150
150
 
151
151
  # Offense count: 1
@@ -244,7 +244,7 @@ Style/SymbolProc:
244
244
  - 'lib/puppet-syntax/manifests.rb'
245
245
  - 'lib/puppet-syntax/templates.rb'
246
246
 
247
- # Offense count: 3
247
+ # Offense count: 2
248
248
  # This cop supports safe autocorrection (--autocorrect).
249
249
  # Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, AllowedPatterns.
250
250
  # URISchemes: http, https
data/CHANGELOG.md CHANGED
@@ -2,6 +2,20 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file.
4
4
 
5
+ ## [v4.0.1](https://github.com/voxpupuli/puppet-syntax/tree/v4.0.1) (2024-03-12)
6
+
7
+ [Full Changelog](https://github.com/voxpupuli/puppet-syntax/compare/v4.0.0...v4.0.1)
8
+
9
+ **Fixed bugs:**
10
+
11
+ - Raise warning if hiera check is called but disabled [\#165](https://github.com/voxpupuli/puppet-syntax/pull/165) ([bastelfreak](https://github.com/bastelfreak))
12
+
13
+ **Merged pull requests:**
14
+
15
+ - Drop Puppet 5.4 check [\#166](https://github.com/voxpupuli/puppet-syntax/pull/166) ([bastelfreak](https://github.com/bastelfreak))
16
+ - README.md: Update required Puppet/Ruby versions [\#164](https://github.com/voxpupuli/puppet-syntax/pull/164) ([bastelfreak](https://github.com/bastelfreak))
17
+ - Update voxpupuli-rubocop requirement from ~\> 2.4.0 to ~\> 2.5.0 [\#163](https://github.com/voxpupuli/puppet-syntax/pull/163) ([dependabot[bot]](https://github.com/apps/dependabot))
18
+
5
19
  ## [v4.0.0](https://github.com/voxpupuli/puppet-syntax/tree/v4.0.0) (2024-02-07)
6
20
 
7
21
  [Full Changelog](https://github.com/voxpupuli/puppet-syntax/compare/v3.3.0...v4.0.0)
data/README.md CHANGED
@@ -15,8 +15,8 @@ Hiera YAML.
15
15
 
16
16
  Puppet::Syntax is supported with:
17
17
 
18
- - Puppet >= 5.0 that provides the `validate` face.
19
- - Ruby >= 2.4
18
+ - Puppet >= 7.0
19
+ - Ruby >= 2.7
20
20
 
21
21
  For the specific versions that we test against, see the [GitHub Actions workflow](.github/workflows/test.yml).
22
22
 
@@ -61,7 +61,7 @@ module PuppetSyntax
61
61
  private
62
62
 
63
63
  def validate_manifest(file)
64
- Puppet[:tasks] = true if Puppet::Util::Package.versioncmp(Puppet.version, '5.4.0') >= 0 and file.match(%r{.*plans/.*\.pp$})
64
+ Puppet[:tasks] = true if %r{.*plans/.*\.pp$}.match?(file)
65
65
  Puppet::Face[:parser, :current].validate(file)
66
66
  end
67
67
  end
@@ -26,7 +26,7 @@ module PuppetSyntax
26
26
  end
27
27
 
28
28
  def initialize(*_args)
29
- desc 'Syntax check Puppet manifests and templates'
29
+ desc 'Syntax check for Puppet manifests, templates and Hiera'
30
30
  task syntax: [
31
31
  'syntax:manifests',
32
32
  'syntax:templates',
@@ -69,6 +69,7 @@ module PuppetSyntax
69
69
  namespace :hiera do
70
70
  task :yaml do |t|
71
71
  warn "---> #{t.name}"
72
+ warn "#{t.name} was called, but PuppetSyntax.check_hiera_keys is false. hiera syntax won't be checked" unless PuppetSyntax.check_hiera_keys
72
73
  c = PuppetSyntax::Hiera.new
73
74
  errors = c.check(filelist_hiera_yaml)
74
75
  $stdout.puts "#{errors.join("\n")}\n" unless errors.empty?
@@ -1,3 +1,3 @@
1
1
  module PuppetSyntax
2
- VERSION = '4.0.0'
2
+ VERSION = '4.0.1'
3
3
  end
@@ -24,5 +24,5 @@ Gem::Specification.new do |spec|
24
24
  spec.add_development_dependency 'pry', '~> 0.14.2'
25
25
  spec.add_development_dependency 'rb-readline', '~> 0.5.5'
26
26
 
27
- spec.add_development_dependency 'voxpupuli-rubocop', '~> 2.4.0'
27
+ spec.add_development_dependency 'voxpupuli-rubocop', '~> 2.5.0'
28
28
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: puppet-syntax
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.0
4
+ version: 4.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vox Pupuli
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-02-07 00:00:00.000000000 Z
11
+ date: 2024-03-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: puppet
@@ -78,14 +78,14 @@ dependencies:
78
78
  requirements:
79
79
  - - "~>"
80
80
  - !ruby/object:Gem::Version
81
- version: 2.4.0
81
+ version: 2.5.0
82
82
  type: :development
83
83
  prerelease: false
84
84
  version_requirements: !ruby/object:Gem::Requirement
85
85
  requirements:
86
86
  - - "~>"
87
87
  - !ruby/object:Gem::Version
88
- version: 2.4.0
88
+ version: 2.5.0
89
89
  description: Syntax checks for Puppet manifests and templates
90
90
  email:
91
91
  - voxpupuli@groups.io