Returns the modification time of stat.
File.stat("testfile").mtime #=> Wed Apr 09 08:53:14 CDT 2003
Returns the birth time for stat.
If the platform doesn’t have birthtime, raises NotImplementedError
.
File.write("testfile", "foo") sleep 10 File.write("testfile", "bar") sleep 10 File.chmod(0644, "testfile") sleep 10 File.read("testfile") File.stat("testfile").birthtime #=> 2014-02-24 11:19:17 +0900 File.stat("testfile").mtime #=> 2014-02-24 11:19:27 +0900 File.stat("testfile").ctime #=> 2014-02-24 11:19:37 +0900 File.stat("testfile").atime #=> 2014-02-24 11:19:47 +0900
Produce a nicely formatted description of stat.
File.stat("/etc/passwd").inspect #=> "#<File::Stat dev=0xe000005, ino=1078078, mode=0100644, # nlink=1, uid=0, gid=0, rdev=0x0, size=1374, blksize=4096, # blocks=8, atime=Wed Dec 10 10:16:12 CST 2003, # mtime=Fri Sep 12 15:41:41 CDT 2003, # ctime=Mon Oct 27 11:20:27 CST 2003, # birthtime=Mon Aug 04 08:13:49 CDT 2003>"
Returns true
if the named file is a directory, or a symlink that points at a directory, and false
otherwise.
file_name can be an IO
object.
File.directory?(".")
Returns true
if stat has its sticky bit set, false
if it doesn’t or if the operating system doesn’t support this feature.
File.stat("testfile").sticky? #=> false
Returns true
if key
is registered
Returns a human-readable string representation of this instruction sequence, including the label
and path
.
A summary of cookie string.
A summary of fields, by header, in an ASCII compatible String.
Shows the mode and size of this table in a US-ASCII String.
Starts the DRb
main loop in a new thread.
Returns an array of the eigenvectors
Symmetric Householder reduction to tridiagonal form.
Symmetric tridiagonal QL algorithm.
Sends the ACCT command.
This is a less common FTP
command, to send account information if the destination host requires it.
Returns the last modification time of the (remote) file. If local
is true
, it is returned as a local time, otherwise it’s a UTC time.
Sends a UNLOCK request to the path
and gets a response, as an HTTPResponse
object.