module FileUtils

Extended Modules

Defined in:

Instance Method Summary

Instance Method Detail

def cmp(stream1 : IO, stream2 : IO) #

[View source]
def cmp(filename1 : String, filename2 : String) #

[View source]
def cp(srcs : Enumerable(String), dest : String) #

Copies a list of files src to dest. dest must be an existing directory.

FileUtils.cp({"", "", ""}, "files")

[View source]
def cp(src_path : String, dest : String) #

Copies the file src_path to the file or directory dest. If dest is a directory, a file with the same basename as src_path is created in dest Permission bits are copied too.

FileUtils.cp("", "")

[View source]
def cp_r(src_path : String, dest_path : String) #

Copies a file or directory src_path to dest_path If src_path is a directory, this method copies all its contents recursively

FileUtils.cp_r("src_dir", "src_dir_copy")

[View source]
def rm_r(path : String) #

Deletes a file or directory path If path is a directory, this method removes all its contents recursively


[View source]