summaryrefslogtreecommitdiffstats
path: root/lib/puppet.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/puppet.rb')
-rw-r--r--lib/puppet.rb43
1 files changed, 0 insertions, 43 deletions
diff --git a/lib/puppet.rb b/lib/puppet.rb
index 66a52f9e3..83e5da68f 100644
--- a/lib/puppet.rb
+++ b/lib/puppet.rb
@@ -117,49 +117,6 @@ module Puppet
# Load all of the configuration parameters.
require 'puppet/defaults'
- # Prints the contents of a config file with the available config elements, or it
- # prints a single value of a config element.
- def self.genconfig
- if Puppet[:configprint] != ""
- val = Puppet[:configprint]
- if val == "all"
- hash = {}
- Puppet.settings.each do |name, obj|
- val = obj.value
- case val
- when true, false, "": val = val.inspect
- end
- hash[name] = val
- end
- hash.sort { |a,b| a[0].to_s <=> b[0].to_s }.each do |name, val|
- puts "%s = %s" % [name, val]
- end
- elsif val =~ /,/
- val.split(/\s*,\s*/).sort.each do |v|
- if Puppet.settings.include?(v)
- puts "%s = %s" % [v, Puppet[v]]
- else
- puts "invalid parameter: %s" % v
- exit(1)
- end
- end
- else
- val.split(/\s*,\s*/).sort.each do |v|
- if Puppet.settings.include?(v)
- puts Puppet[val]
- else
- puts "invalid parameter: %s" % v
- exit(1)
- end
- end
- end
- exit(0)
- end
- if Puppet[:genconfig]
- puts Puppet.settings.to_config
- exit(0)
- end
- end
def self.genmanifest
if Puppet[:genmanifest]