summaryrefslogtreecommitdiff
path: root/Rakefile
diff options
context:
space:
mode:
authorGuido Günther <agx@sigxcpu.org>2014-04-10 17:18:21 +0200
committerGuido Günther <agx@sigxcpu.org>2014-04-11 09:08:57 +0200
commitc0eab58bc6bcfb26275349d817bf8746902a221a (patch)
treef40261bdb699c3b734babbc3ff2476c4b0c93e10 /Rakefile
Initial commit
Diffstat (limited to 'Rakefile')
-rw-r--r--Rakefile18
1 files changed, 18 insertions, 0 deletions
diff --git a/Rakefile b/Rakefile
new file mode 100644
index 0000000..4ed1327
--- /dev/null
+++ b/Rakefile
@@ -0,0 +1,18 @@
+require 'rubygems'
+require 'puppetlabs_spec_helper/rake_tasks'
+require 'puppet-lint/tasks/puppet-lint'
+PuppetLint.configuration.send('disable_80chars')
+PuppetLint.configuration.ignore_paths = ["spec/**/*.pp", "pkg/**/*.pp"]
+
+desc "Validate manifests, templates, and ruby files in lib."
+task :validate do
+ Dir['manifests/**/*.pp'].each do |manifest|
+ sh "puppet parser validate --noop #{manifest}"
+ end
+ Dir['lib/**/*.rb'].each do |lib_file|
+ sh "ruby -c #{lib_file}"
+ end
+ Dir['templates/**/*.erb'].each do |template|
+ sh "erb -P -x -T '-' #{template} | ruby -c"
+ end
+end