File
Description
Class Methods
#
extname ( filename ) => String
( source )
#
chmod ( filename ) => Integer
Changes the mode of the file. Return number of files.
File.chmod(0755, "test.sh") # => 1
File.chmod(0755, "goby", "../test.sh") # => 2
( source )
#
size ( filename ) => Integer
Returns size of file in bytes.
File.size("loop.gb") # => 321123
( source )
#
basename ( filepath ) => String
Returns the last element from path.
File.basename("/home/goby/plugin/loop.gb") # => loop.gb
( source )
#
join => String
Returns string with joined elements.
File.join("home", "goby", "plugin") # => home/goby/plugin
- Return: (String) : No Doc
( source )
#
split ( filepath ) => Array
Returns array of path and file.
File.split("/home/goby/.settings") # => ["/home/goby/", ".settings"]
( source )
Returns extension part of a File