module

Dust::Utils

Instance methods

absolute?(path : String) : Bool
Source
canonical(path : String) : String
Source
excluded?(filters : Array(Regex), path : String) : Bool
Source
join(dir : String, child : String) : String

Path::join: an absolute child replaces the parent entirely, an empty child leaves the parent untouched.

Source
normalize(path : String) : String

Mirrors Path::components().collect(): drops repeated separators, . components and trailing separators. .. is kept, as Rust keeps it.

Source
parent?(parent : String, child : String) : Bool

parent is a strict ancestor of child. Both paths are normalized first, so "/usr" is not treated as the parent of "/usr/.".

Source
simplify(dirs : Array(String)) : Set(String)

Removes directories that are already covered by another entry, so that dust a/b a/b/c only walks a/b.

Source
unmatched?(filters : Array(Regex), path : String) : Bool
Source