Method: GrubConfig#initialize

Defined in:
lib/resources/grub_conf.rb

#initialize(path = nil, kernel = nil) ⇒ GrubConfig

Returns a new instance of GrubConfig.



28
29
30
31
32
33
34
# File 'lib/resources/grub_conf.rb', line 28

def initialize(path = nil, kernel = nil)
  config_for_platform(path)
  @content = read_file(@conf_path)
  @kernel = kernel || 'default'
rescue UnknownGrubConfig
  return skip_resource 'The `grub_config` resource is not supported on your OS yet.'
end