class Nova::Remote::Fake::FileSystem
Handles filesystem stuff, like downloading files and decompressing ifles.
Public Instance Methods
Decompress the given file, to the given directory.
@note Does nothing. @abstract @param file [String] the file to decompress. @param to [String] the directory to decompress to. @return [void]
# File lib/nova/remote/fake/file_system.rb, line 47 def decompress_file(file, to) end
Checks to see if the file exists on the file system.
@note Does nothing. @abstract @param file [String] the file to check. @return [Boolean]
# File lib/nova/remote/fake/file_system.rb, line 36 def file_exists?(file) false end
Grabs the file from file and puts it somewhere else. If it’s a local file (checked by file_exists?
), it just copies it. If it’s not, it opens a connection to the server to try to download the file.
@note Does nothing. @abstract @param file [String] the file to download. Can be a path
name or URI.
@param options [Hash{Symbol => Object}] the options for
grabbing the files.
@option options [String] :to the file to save to. If this
doesn't exist, it's guessed from the file name.
@option options [Boolean, String] :decompress the file after
saving it. If it's a string, the decompressed file is extracted there. Otherwise, it's guessed from the filename.
@return [Boolean]
# File lib/nova/remote/fake/file_system.rb, line 26 def grab_file(file, options = {}) false end
Private Instance Methods
Unrars the given file.
@note Does nothing. @abstract
# File lib/nova/remote/fake/file_system.rb, line 71 def unrar_file(f, to) end
Untars the given file.
@note Does nothing. @abstract @return [void]
# File lib/nova/remote/fake/file_system.rb, line 57 def untar_file(f, to) end
Unzips the file.
@note Does nothing. @abstract
# File lib/nova/remote/fake/file_system.rb, line 64 def unzip_file(f, to) end