class Chef::Resource::Link
Public Class Methods
new(name, run_context = nil)
click to toggle source
Calls superclass method
Chef::Resource.new
# File lib/chef/resource/link.rb, line 45 def initialize(name, run_context = nil) verify_links_supported! super end
Public Instance Methods
path()
click to toggle source
make link quack like a file (XXX: not for public consumption)
# File lib/chef/resource/link.rb, line 57 def path target_file end
Private Instance Methods
verify_links_supported!()
click to toggle source
# File lib/chef/resource/link.rb, line 63 def verify_links_supported! # On certain versions of windows links are not supported. Make # sure we are not on such a platform. if Chef::Platform.windows? require "chef/win32/file" begin Chef::ReservedNames::Win32::File.verify_links_supported! rescue Chef::Exceptions::Win32APIFunctionNotImplemented => e Chef::Log.fatal("Link resource is not supported on this version of Windows") raise e end end end