bin/ppdb in hieracles-0.3.0 vs bin/ppdb in hieracles-0.3.1
- old
+ new
@@ -29,12 +29,12 @@
puts "*** Unknown command: #{command}"
puts Hieracles::Options::Ppdb.usage
exit(1)
end
-Hieracles::Config.load opt.options
+config = Hieracles::Config.new opt.options
-request = Hieracles::Puppetdb::Request.new Hieracles::Config.puppetdb
+request = Hieracles::Puppetdb::Request.new config.puppetdb
meth = request.method(command.to_sym)
required = request.method(command.to_sym).parameters.select { |arg| arg[0] == :req }.map { |arg| arg[1] }
if args.length < required.length
args = required.join(', ')
puts "*** The #{command} method requires arguments: #{args}"