mtime(filename, local = false)
public
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.
Show source
def mtime(filename, local = false)
str = mdtm(filename)
ary = str.scan(MDTM_REGEXP)[0].collect {|i| i.to_i}
return local ? Time.local(*ary) : Time.gm(*ary)
end