puppet-lint 0.1.4 → 0.1.5
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.
- data/bin/puppet-lint +9 -0
- data/lib/puppet-lint.rb +1 -1
- data/puppet-lint.gemspec +1 -1
- metadata +4 -4
data/bin/puppet-lint
CHANGED
@@ -17,6 +17,7 @@ require 'optparse'
|
|
17
17
|
require 'rubygems'
|
18
18
|
require 'puppet-lint'
|
19
19
|
|
20
|
+
options = {}
|
20
21
|
opts = OptionParser.new do |opts|
|
21
22
|
opts.banner = help
|
22
23
|
|
@@ -24,6 +25,10 @@ opts = OptionParser.new do |opts|
|
|
24
25
|
puts "Puppet-lint " + PuppetLint::VERSION
|
25
26
|
exit 0
|
26
27
|
end
|
28
|
+
|
29
|
+
opts.on("--fail-on-warnings", "Return a non-zero exit status for warnings.") do
|
30
|
+
options[:fail_on_warnings] = true
|
31
|
+
end
|
27
32
|
end
|
28
33
|
|
29
34
|
# Read command line options into `options` hash
|
@@ -45,6 +50,10 @@ begin
|
|
45
50
|
l = PuppetLint.new
|
46
51
|
l.file = ARGV[0]
|
47
52
|
l.run
|
53
|
+
|
54
|
+
if l.errors? or (l.warnings? and options[:fail_on_warnings])
|
55
|
+
exit 1
|
56
|
+
end
|
48
57
|
rescue PuppetLint::NoCodeError
|
49
58
|
puts "puppet-lint: no file specified or specified file does not exist"
|
50
59
|
puts "puppet-lint: try 'puppet-lint --help' for more information"
|
data/lib/puppet-lint.rb
CHANGED
data/puppet-lint.gemspec
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
2
|
s.name = 'puppet-lint'
|
3
|
-
s.version = '0.1.
|
3
|
+
s.version = '0.1.5'
|
4
4
|
s.homepage = 'https://github.com/rodjek/puppet-lint/'
|
5
5
|
s.summary = 'Ensure your Puppet manifests conform with the Puppetlabs style guide'
|
6
6
|
s.description = 'Checks your Puppet manifests against the Puppetlabs
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: puppet-lint
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 17
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 1
|
9
|
-
-
|
10
|
-
version: 0.1.
|
9
|
+
- 5
|
10
|
+
version: 0.1.5
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Tim Sharpe
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2011-
|
18
|
+
date: 2011-10-04 00:00:00 Z
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|
21
21
|
name: rspec
|