Import with #import "std/path".

CleanAbsolute :: (value: string, output: []u8) -> string

Lexical slash-path operations. These do not resolve links or mount points. Returned text borrows output until the caller changes that storage.

WithinDirectory :: (value: string, directory: string) -> bool

Both arguments must be canonical absolute slash paths. A directory prefix matches only itself or a complete component boundary, never a sibling.

Source ↗ · All modules