Sha256: 5c5820786a62069feb1b799f30f6e6c1f878754d040dc11e700d72ffdbff16a0
Contents?: true
Size: 859 Bytes
Versions: 10
Compression:
Stored size: 859 Bytes
Contents
require 'pdk' module PDK module Generate class Provider < PuppetObject def friendly_name 'Resource API Provider'.freeze end def template_files files = { 'provider_spec.erb' => File.join('spec', 'unit', 'puppet', 'provider', object_name, object_name) + '_spec.rb', 'provider_type_spec.erb' => File.join('spec', 'unit', 'puppet', 'type', object_name) + '_spec.rb', } return files if spec_only? files.merge( 'provider.erb' => File.join('lib', 'puppet', 'provider', object_name, object_name) + '.rb', 'provider_type.erb' => File.join('lib', 'puppet', 'type', object_name) + '.rb', ) end def template_data { name: object_name, provider_class: class_name_from_object_name(object_name) } end end end end
Version data entries
10 entries across 10 versions & 1 rubygems