open(path, mode)
public
CommandProcessor#open(path, mode)
path: String
mode: String
return: File or Dir
Same as:
File
Dir
mode has an effect only when path is a file
Show source
def open(path, mode)
path = expand_path(path)
if File.directory?(path)
Dir.open(path)
else
effect_umask do
File.open(path, mode)
end
end
end