Pathname
Inherits Comparable < Struct < Value < Object
Constants
VERSION = "0.1.6"
Constructors
new(path : String)
SourceClass methods
cwd
Sourceglob(patterns : Enumerable(String), &)
Sourceglob(*patterns, &)
Sourceglob(patterns : Enumerable(String))
Sourceglob(*patterns)
SourceInstance methods
<=>(other : Pathname)
The comparison operator. Returns 0 if the two objects are equal,
a negative number if this object is considered less than other,
a positive number if this object is considered greater than other,
or nil if the two objects are not comparable.
Subclasses define this method to provide class-specific ordering.
The comparison operator is usually used to sort values:
# Sort in a descending way:
[3, 1, 2].sort { |x, y| y <=> x } # => [3, 2, 1]
# Sort in an ascending way:
[3, 1, 2].sort { |x, y| x <=> y } # => [1, 2, 3]
absolute?
Sourceascend
Sourceatime
Sourcebasename
Sourceblockdev?
Sourcechardev?
Sourcectime
Sourcedelete
Sourcedescend
Sourcedirectory?
Sourcedirname
Sourceeach_child(with_directory : Bool = true, &)
Sourceeach_entry
Sourceeach_filename
Sourceeach_line
Sourceentries
Sourceexecutable?
Sourceexists?
Sourceextname
Sourcefile?
Sourcefilenames
Sourceinspect(io)
Sourcelstat
Sourcemake_link(old)
Sourcemake_symlink(old)
Sourcemkdir(mode = 329)
Sourcemkdir_p(mode = 329)
Sourcemtime
Sourceopen(mode = "r", perm = DEFAULT_CREATE_MODE)
Sourceopen(mode = "r", perm = DEFAULT_CREATE_MODE, &)
Sourceopendir
Sourceopendir
Sourceparent
Sourceread(encoding = nil, invalid = nil) : String
Sourcereadable?
Sourcereal_path
Sourcerelative?
Sourcerename(to)
Sourcermdir
Sourceroot?
Sourcesetgid?
Sourcesetuid?
Sourcesize
Sourcesize?
Sourcesocket?
Sourcesplit
Sourcestat
Sourcesticky?
Sourcesub(pattern, &)
Sourcesub_ext(replace : String)
Sourcesymlink?
Sourceto_s(io)
Sourcetruncate(size = 0)
Sourceutime
Sourceworld_readable?
Sourceworld_writable?
Sourcewritable?
Sourcewrite(content, perm = DEFAULT_CREATE_MODE, encoding = nil, invalid = nil)
Sourcezero?
Source