Skip to content

Commit

Permalink
Initialize puppet environment due to upgrade puppet version
Browse files Browse the repository at this point in the history
  • Loading branch information
dieterdemeyer committed Jul 31, 2014
1 parent 38c243b commit 8535225
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tasks/rake/syntax.rake
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,16 @@ task :syntax do
fail 'Cannot load puppet/face, are you sure you have Puppet 2.7?'
end

Puppet.initialize_settings

puts "Checking puppet module syntax..."

success = true

FileList['**/*.pp'].each do |manifest|
puts "Evaluating syntax for #{manifest}"
begin
Puppet::Face[:parser, '0.0.1'].validate(manifest)
Puppet::Face[:parser, '0.0.1'].validate(manifest)
rescue Puppet::Error => error
puts error.message
success = false
Expand Down

0 comments on commit 8535225

Please sign in to comment.