Stdlib module path.vitl
This page is a wiki-style reference for one concrete stdlib file. It explains what the file owns, where it fits in the family, and how to decide whether this is the right surface to depend on.
path.vitl.Family: path
Kind: public stdlib surface
Page style: this reference follows the same “encyclopedic card + portrait + usage contract” logic as the keyword pages, but for stdlib modules.
Summary
- Overview
- Purpose
- Taxonomy
- Implementation profile
- Top-level API inventory
- Position in family
- Declaration map
- Representative signatures
- How to use this module
- User example
- Keyword coverage
- Source shape
- Source landmarks
- Source organization
- Complete API catalog
- Integration boundaries
- Composition guidance
- Relationship table
- Neighbor modules
Overview
| Field | Value |
|---|---|
| Path | path.vitl |
| Family | path |
| Kind | public stdlib surface |
| Line count | 1066 |
| Declared procedures | 79 |
| Declared forms/picks | 6 |
`path.vitl` is a public stdlib surface inside the `path` family. It should be read as one focused slice of the broader family responsibility: Path manipulation, special locations, walkers, and globbing.
Purpose
This file should be chosen because of responsibility, not because its name “sounds close enough”. Inside the path family, it carries one focused part of the contract and keeps that responsibility separate from neighboring concerns.
- Use this module when bytes or paths cross a host boundary and architecture must keep that boundary visible.
- A project root can be normalized before any file is read.
- A walker can enumerate source files while parsing and diagnostics remain elsewhere.
Taxonomy
Think of this page as a generated encyclopedia entry rather than a hand-written tutorial. The goal is to show what kind of module this is, how dense it is, and what reading strategy makes sense before depending on it.
- Large algorithm surface: this file exposes many procedures and likely acts as a domain toolkit rather than a single thin wrapper.
- Owns domain vocabulary: the module declares data shapes in addition to executable helpers, so its types are part of the contract.
- Has tuning constants: part of the module behavior is controlled by named constants that document default precision, limits, or policy.
- Minimal top-level dependencies: the module reads as mostly self-contained from its opening declarations.
- Explicit export surface: the file ends with visible export declarations instead of relying only on implicit namespace discovery.
Implementation profile
This profile is inferred directly from the source text. It does not replace reading the file, but it tells you quickly whether the module is mostly declarative, loop-heavy, branch-heavy, or organized around many small exits.
| Signal | Count | What it suggests |
|---|---|---|
if | 102 | Branching density and local decision-making. |
while | 30 | Loop-heavy or iterative implementation style. |
for | 0 | Collection-style traversal at source level. |
match | 5 | Variant-driven branching or grammar-style decoding. |
let | 152 | Local state and intermediate value density. |
give | 144 | Number of explicit exit points and result shaping. |
Top-level API inventory
| Surface | Items |
|---|---|
| Procedures | listdir, getenv, getcwd, setenv, access, stat, lstat, _path_slice, _path_strip_trailing_separator, _path_split, _path_join_parts, _path_remove_last_component |
| Forms | Path, PathWalker, PathLibraryManifest, PathLibraryHealth, PathLibrarySummary, FileStat |
| Picks | none declared at top level |
| Constants | PATH_SEPARATOR, PATH_DELIMITER, S_ISREG, S_ISDIR, S_ISLNK |
| Exports | * |
Imported surfaces
This file does not advertise a top-level `use` surface in its opening declarations. That often means it is either self-contained or an aggregation layer.
Position in family
This file is module 1 of 5 in the path family when ordered by path. By procedure count it ranks 1, and by line count it ranks 1. Those ranks are useful as rough signals of breadth, not as quality judgments.
Declaration map
The declaration map turns raw source into a scan-friendly catalog. It is useful when the file is large enough that a reader wants to orient by kinds of surfaces first.
| Line | Name | Kind | Role |
|---|---|---|---|
| 1 | vitte/path | space | Declares the namespace that anchors this file in the stdlib tree. |
| 7 | PATH_SEPARATOR | const | Defines a named constant reused across the module. |
| 8 | PATH_DELIMITER | const | Defines a named constant reused across the module. |
| 10 | Path | form | Introduces a structured data shape that other procedures can exchange. |
| 15 | PathWalker | form | Introduces a structured data shape that other procedures can exchange. |
| 21 | PathLibraryManifest | form | Introduces a structured data shape that other procedures can exchange. |
| 27 | PathLibraryHealth | form | Introduces a structured data shape that other procedures can exchange. |
| 36 | PathLibrarySummary | form | Introduces a structured data shape that other procedures can exchange. |
| 41 | FileStat | form | Introduces a structured data shape that other procedures can exchange. |
| 45 | S_ISREG | const | Defines a named constant reused across the module. |
| 46 | S_ISDIR | const | Defines a named constant reused across the module. |
| 47 | S_ISLNK | const | Defines a named constant reused across the module. |
| 49 | listdir | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 53 | getenv | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 57 | getcwd | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 61 | setenv | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 65 | access | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 69 | stat | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 75 | lstat | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 82 | _path_slice | proc | Owns path semantics, traversal, or normalization. |
| 93 | _path_strip_trailing_separator | proc | Owns path semantics, traversal, or normalization. |
| 107 | _path_split | proc | Owns path semantics, traversal, or normalization. |
| 133 | _path_join_parts | proc | Owns path semantics, traversal, or normalization. |
| 158 | _path_remove_last_component | proc | Owns path semantics, traversal, or normalization. |
| 171 | _path_segment_matches | proc | Owns path semantics, traversal, or normalization. |
| 215 | _path_match_parts | proc | Owns path semantics, traversal, or normalization. |
| 245 | _path_collect_recursive | proc | Owns path semantics, traversal, or normalization. |
| 274 | _join_strings | proc | Owns path semantics, traversal, or normalization. |
| 287 | _get_env_variable | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 295 | path_version | proc | Owns path semantics, traversal, or normalization. |
| 299 | path_name | proc | Owns path semantics, traversal, or normalization. |
| 303 | path_module_count | proc | Owns path semantics, traversal, or normalization. |
| 307 | path_modules | proc | Owns path semantics, traversal, or normalization. |
| 316 | path_manifest | proc | Owns path semantics, traversal, or normalization. |
| 324 | path_ready | proc | Owns path semantics, traversal, or normalization. |
| 328 | path_health | proc | Owns path semantics, traversal, or normalization. |
| 339 | path_summary | proc | Owns path semantics, traversal, or normalization. |
| 346 | path_selftest | proc | Owns path semantics, traversal, or normalization. |
| 356 | path_new | proc | Owns path semantics, traversal, or normalization. |
| 363 | path_normalize | proc | Owns path semantics, traversal, or normalization. |
| 404 | path_resolve | proc | Owns path semantics, traversal, or normalization. |
| 415 | path_absolute | proc | Owns path semantics, traversal, or normalization. |
| 419 | path_relative | proc | Owns path semantics, traversal, or normalization. |
| 461 | path_get_parent | proc | Owns path semantics, traversal, or normalization. |
| 497 | path_get_filename | proc | Owns path semantics, traversal, or normalization. |
| 514 | path_get_basename | proc | Owns path semantics, traversal, or normalization. |
| 518 | path_get_stem | proc | Owns path semantics, traversal, or normalization. |
| 532 | path_get_extension | proc | Owns path semantics, traversal, or normalization. |
| 547 | path_get_directory | proc | Owns path semantics, traversal, or normalization. |
| 551 | path_get_root | proc | Owns path semantics, traversal, or normalization. |
| 559 | path_join | proc | Owns path semantics, traversal, or normalization. |
| 586 | path_join_multi | proc | Owns path semantics, traversal, or normalization. |
| 596 | path_with_extension | proc | Owns path semantics, traversal, or normalization. |
| 617 | path_with_filename | proc | Owns path semantics, traversal, or normalization. |
| 626 | path_exists | proc | Owns path semantics, traversal, or normalization. |
| 630 | path_is_file | proc | Owns path semantics, traversal, or normalization. |
| 636 | path_is_dir | proc | Owns path semantics, traversal, or normalization. |
| 642 | path_is_symlink | proc | Owns path semantics, traversal, or normalization. |
| 648 | path_is_absolute | proc | Owns path semantics, traversal, or normalization. |
| 657 | path_is_relative | proc | Owns path semantics, traversal, or normalization. |
| 664 | path_is_hidden | proc | Owns path semantics, traversal, or normalization. |
| 673 | path_equals | proc | Owns path semantics, traversal, or normalization. |
| 677 | path_starts_with | proc | Owns path semantics, traversal, or normalization. |
| 693 | path_ends_with | proc | Owns path semantics, traversal, or normalization. |
| 712 | path_matches | proc | Owns path semantics, traversal, or normalization. |
| 720 | path_glob | proc | Owns path semantics, traversal, or normalization. |
| 735 | path_glob_recursive | proc | Owns path semantics, traversal, or normalization. |
| 740 | path_walk | proc | Owns path semantics, traversal, or normalization. |
| 765 | path_walk_recursive | proc | Owns path semantics, traversal, or normalization. |
| 773 | path_walker_next | proc | Owns path semantics, traversal, or normalization. |
| 782 | path_walker_has_next | proc | Owns path semantics, traversal, or normalization. |
| 787 | path_clean | proc | Owns path semantics, traversal, or normalization. |
| 791 | path_canonicalize | proc | Owns path semantics, traversal, or normalization. |
| 795 | path_simplify | proc | Owns path semantics, traversal, or normalization. |
| 799 | path_expand_home | proc | Owns path semantics, traversal, or normalization. |
| 815 | path_expand_env | proc | Owns path semantics, traversal, or normalization. |
| 868 | home_dir | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 890 | temp_dir | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 909 | current_dir | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 917 | config_dir | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 925 | cache_dir | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 933 | desktop_dir | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 941 | documents_dir | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 949 | downloads_dir | proc | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 958 | get_path_env | proc | Owns path semantics, traversal, or normalization. |
| 988 | find_in_path | proc | Owns path semantics, traversal, or normalization. |
| 1014 | add_to_path | proc | Owns path semantics, traversal, or normalization. |
| 1032 | remove_from_path | proc | Owns path semantics, traversal, or normalization. |
| 1051 | path_segments | proc | Owns path semantics, traversal, or normalization. |
| 1055 | path_depth | proc | Owns path semantics, traversal, or normalization. |
| 1059 | path_report | proc | Owns path semantics, traversal, or normalization. |
The table is exhaustive for top-level declarations of the selected kinds. This file declares 91 matching surfaces.
Representative signatures
These signatures are shown in source order so the page keeps the feel of a reference manual, not just a keyword cloud.
const PATH_SEPARATOR: string = "/"(line 7)const PATH_DELIMITER: string = ":"(line 8)form Path {(line 10)form PathWalker {(line 15)form PathLibraryManifest {(line 21)form PathLibraryHealth {(line 27)form PathLibrarySummary {(line 36)form FileStat {(line 41)const S_ISREG: i32 = 1(line 45)const S_ISDIR: i32 = 2(line 46)const S_ISLNK: i32 = 4(line 47)proc listdir(root: string) -> [string] {(line 49)proc getenv(name: string) -> string {(line 53)proc getcwd() -> string {(line 57)proc setenv(name: string, value: string, overwrite: i32) -> i32 {(line 61)proc access(p: string, mode: i32) -> i32 {(line 65)proc stat(p: string) -> FileStat {(line 69)proc lstat(p: string) -> FileStat {(line 75)
The list is intentionally capped here; the source file declares 90 matching signatures in total.
How to use this module
Start by reading the file as an ownership boundary. Ask three questions: what enters this module, what stable types or procedures it exports, and what adjacent module should stay outside of it.
- Read
spaceand top-level imports first so the ownership boundary ofpath.vitlis explicit. - Scan constants before procedures; they often encode precision, limits, or policy assumptions that explain later behavior.
- Read declared forms and picks before algorithms so the data vocabulary is stable in your head.
- Traverse procedures in source order; the early helpers usually explain the naming and numeric conventions used later.
- Use the source landmarks section below as a table of contents when the file is large.
User example
This example is generated from the actual stdlib module surface. Its job is not to be the smallest snippet possible; its job is to show a realistic consumer-shaped file that exercises the module and mirrors the language keywords the module itself relies on.
space demo/path
const ROOT: string = "src"
form PathRun {
pattern: string,
ready: bool
}
proc run_example() -> PathRun {
let entries = path_glob("src/*.vitl")
let ready: bool = path_selftest() == 0
let stable: bool = ready and entries.len >= 0
if not ready {
give PathRun { pattern: "not-ready", ready: false }
} else {
give PathRun { pattern: "src/**/*.vitl", ready: true }
}
}
export run_example
Keyword coverage
This table makes the “all keywords of the module” requirement auditable. It compares the detected Vitte keywords in the source file with the generated consumer example above.
| Keyword | Present in module source | Used in generated user example |
|---|---|---|
space | yes | yes |
const | yes | yes |
form | yes | yes |
proc | yes | yes |
let | yes | yes |
set | yes | no |
if | yes | yes |
else | yes | yes |
while | yes | no |
match | yes | no |
give | yes | yes |
entry | yes | no |
export | yes | yes |
true | yes | yes |
and | yes | yes |
or | yes | no |
not | yes | yes |
as | yes | no |
Keywords still not exercised directly in the generated snippet: set, while, match, entry, or, as. The page still lists them here so the gap is visible.
Source shape
space vitte/path
const PATH_SEPARATOR: string = "/"
const PATH_DELIMITER: string = ":"
form Path {
path_str: string,
components: [string]
}
form PathWalker {
root: string,
entries: [string],
The excerpt is not meant to replace the file. It exists to make the module recognizable at first glance, the same way a Wikipedia infobox helps the reader orient before reading the whole article.
Source landmarks
Large files are easier to retain when they have visible landmarks. When the source contains explicit section banners, they are surfaced here; otherwise the first major declarations are used as anchors.
- Path and Filesystem Utilities — Path manipulation
Source organization
When a file carries its own internal chaptering, those chapters usually reveal the intended reading order better than a flat symbol list. This section reconstructs that organization from the source itself.
Opening declarations
Top-level items: 1. Procedures: 0. Data surfaces: 0. Constants: 0.
First visible names: vitte/path
Path and Filesystem Utilities — Path manipulation
Top-level items: 91. Procedures: 79. Data surfaces: 6. Constants: 5.
First visible names: PATH_SEPARATOR, PATH_DELIMITER, Path, PathWalker, PathLibraryManifest, PathLibraryHealth, PathLibrarySummary, FileStat, S_ISREG, S_ISDIR
Complete API catalog
This catalog is the exhaustive file-level index for the module. It is intentionally closer to a generated encyclopedia appendix than to a tutorial summary.
Constants
| Line | Name | Signature | Role |
|---|---|---|---|
| 7 | PATH_SEPARATOR | const PATH_SEPARATOR: string = "/" | Defines a named constant reused across the module. |
| 8 | PATH_DELIMITER | const PATH_DELIMITER: string = ":" | Defines a named constant reused across the module. |
| 45 | S_ISREG | const S_ISREG: i32 = 1 | Defines a named constant reused across the module. |
| 46 | S_ISDIR | const S_ISDIR: i32 = 2 | Defines a named constant reused across the module. |
| 47 | S_ISLNK | const S_ISLNK: i32 = 4 | Defines a named constant reused across the module. |
Data surfaces
| Line | Name | Signature | Role |
|---|---|---|---|
| 10 | Path | form Path { | Introduces a structured data shape that other procedures can exchange. |
| 15 | PathWalker | form PathWalker { | Introduces a structured data shape that other procedures can exchange. |
| 21 | PathLibraryManifest | form PathLibraryManifest { | Introduces a structured data shape that other procedures can exchange. |
| 27 | PathLibraryHealth | form PathLibraryHealth { | Introduces a structured data shape that other procedures can exchange. |
| 36 | PathLibrarySummary | form PathLibrarySummary { | Introduces a structured data shape that other procedures can exchange. |
| 41 | FileStat | form FileStat { | Introduces a structured data shape that other procedures can exchange. |
Procedures
| Line | Name | Signature | Role |
|---|---|---|---|
| 49 | listdir | proc listdir(root: string) -> [string] { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 53 | getenv | proc getenv(name: string) -> string { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 57 | getcwd | proc getcwd() -> string { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 61 | setenv | proc setenv(name: string, value: string, overwrite: i32) -> i32 { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 65 | access | proc access(p: string, mode: i32) -> i32 { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 69 | stat | proc stat(p: string) -> FileStat { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 75 | lstat | proc lstat(p: string) -> FileStat { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 82 | _path_slice | proc _path_slice(str: string, start: int, end: int) -> string { | Owns path semantics, traversal, or normalization. |
| 93 | _path_strip_trailing_separator | proc _path_strip_trailing_separator(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 107 | _path_split | proc _path_split(p: string) -> [string] { | Owns path semantics, traversal, or normalization. |
| 133 | _path_join_parts | proc _path_join_parts(parts: [string], absolute: int) -> string { | Owns path semantics, traversal, or normalization. |
| 158 | _path_remove_last_component | proc _path_remove_last_component(parts: [string]) -> [string] { | Owns path semantics, traversal, or normalization. |
| 171 | _path_segment_matches | proc _path_segment_matches(text: string, pattern: string) -> int { | Owns path semantics, traversal, or normalization. |
| 215 | _path_match_parts | proc _path_match_parts(parts: [string], pattern_parts: [string], pi: int, qi: int) -> int { | Owns path semantics, traversal, or normalization. |
| 245 | _path_collect_recursive | proc _path_collect_recursive(root: string, entries: [string]) -> [string] { | Owns path semantics, traversal, or normalization. |
| 274 | _join_strings | proc _join_strings(values: [string], delimiter: string) -> string { | Owns path semantics, traversal, or normalization. |
| 287 | _get_env_variable | proc _get_env_variable(name: string) -> string { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 295 | path_version | proc path_version() -> string { | Owns path semantics, traversal, or normalization. |
| 299 | path_name | proc path_name() -> string { | Owns path semantics, traversal, or normalization. |
| 303 | path_module_count | proc path_module_count() -> i32 { | Owns path semantics, traversal, or normalization. |
| 307 | path_modules | proc path_modules() -> [string] { | Owns path semantics, traversal, or normalization. |
| 316 | path_manifest | proc path_manifest() -> PathLibraryManifest { | Owns path semantics, traversal, or normalization. |
| 324 | path_ready | proc path_ready() -> bool { | Owns path semantics, traversal, or normalization. |
| 328 | path_health | proc path_health() -> PathLibraryHealth { | Owns path semantics, traversal, or normalization. |
| 339 | path_summary | proc path_summary() -> PathLibrarySummary { | Owns path semantics, traversal, or normalization. |
| 346 | path_selftest | proc path_selftest() -> bool { | Owns path semantics, traversal, or normalization. |
| 356 | path_new | proc path_new(p: string) -> Path { | Owns path semantics, traversal, or normalization. |
| 363 | path_normalize | proc path_normalize(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 404 | path_resolve | proc path_resolve(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 415 | path_absolute | proc path_absolute(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 419 | path_relative | proc path_relative(base: string, target: string) -> string { | Owns path semantics, traversal, or normalization. |
| 461 | path_get_parent | proc path_get_parent(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 497 | path_get_filename | proc path_get_filename(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 514 | path_get_basename | proc path_get_basename(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 518 | path_get_stem | proc path_get_stem(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 532 | path_get_extension | proc path_get_extension(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 547 | path_get_directory | proc path_get_directory(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 551 | path_get_root | proc path_get_root(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 559 | path_join | proc path_join(base: string, component: string) -> string { | Owns path semantics, traversal, or normalization. |
| 586 | path_join_multi | proc path_join_multi(base: string, components: [string]) -> string { | Owns path semantics, traversal, or normalization. |
| 596 | path_with_extension | proc path_with_extension(p: string, ext: string) -> string { | Owns path semantics, traversal, or normalization. |
| 617 | path_with_filename | proc path_with_filename(p: string, filename: string) -> string { | Owns path semantics, traversal, or normalization. |
| 626 | path_exists | proc path_exists(p: string) -> int { | Owns path semantics, traversal, or normalization. |
| 630 | path_is_file | proc path_is_file(p: string) -> int { | Owns path semantics, traversal, or normalization. |
| 636 | path_is_dir | proc path_is_dir(p: string) -> int { | Owns path semantics, traversal, or normalization. |
| 642 | path_is_symlink | proc path_is_symlink(p: string) -> int { | Owns path semantics, traversal, or normalization. |
| 648 | path_is_absolute | proc path_is_absolute(p: string) -> int { | Owns path semantics, traversal, or normalization. |
| 657 | path_is_relative | proc path_is_relative(p: string) -> int { | Owns path semantics, traversal, or normalization. |
| 664 | path_is_hidden | proc path_is_hidden(p: string) -> int { | Owns path semantics, traversal, or normalization. |
| 673 | path_equals | proc path_equals(p1: string, p2: string) -> int { | Owns path semantics, traversal, or normalization. |
| 677 | path_starts_with | proc path_starts_with(p: string, prefix: string) -> int { | Owns path semantics, traversal, or normalization. |
| 693 | path_ends_with | proc path_ends_with(p: string, suffix: string) -> int { | Owns path semantics, traversal, or normalization. |
| 712 | path_matches | proc path_matches(p: string, pattern: string) -> int { | Owns path semantics, traversal, or normalization. |
| 720 | path_glob | proc path_glob(pattern: string) -> [string] { | Owns path semantics, traversal, or normalization. |
| 735 | path_glob_recursive | proc path_glob_recursive(pattern: string) -> [string] { | Owns path semantics, traversal, or normalization. |
| 740 | path_walk | proc path_walk(root: string) -> PathWalker { | Owns path semantics, traversal, or normalization. |
| 765 | path_walk_recursive | proc path_walk_recursive(root: string) -> PathWalker { | Owns path semantics, traversal, or normalization. |
| 773 | path_walker_next | proc path_walker_next(w: PathWalker) -> string { | Owns path semantics, traversal, or normalization. |
| 782 | path_walker_has_next | proc path_walker_has_next(w: PathWalker) -> int { | Owns path semantics, traversal, or normalization. |
| 787 | path_clean | proc path_clean(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 791 | path_canonicalize | proc path_canonicalize(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 795 | path_simplify | proc path_simplify(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 799 | path_expand_home | proc path_expand_home(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 815 | path_expand_env | proc path_expand_env(p: string) -> string { | Owns path semantics, traversal, or normalization. |
| 868 | home_dir | proc home_dir() -> string { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 890 | temp_dir | proc temp_dir() -> string { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 909 | current_dir | proc current_dir() -> string { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 917 | config_dir | proc config_dir() -> string { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 925 | cache_dir | proc cache_dir() -> string { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 933 | desktop_dir | proc desktop_dir() -> string { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 941 | documents_dir | proc documents_dir() -> string { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 949 | downloads_dir | proc downloads_dir() -> string { | Represents one top-level surface in the file contract and should be read as part of the module boundary. |
| 958 | get_path_env | proc get_path_env() -> [string] { | Owns path semantics, traversal, or normalization. |
| 988 | find_in_path | proc find_in_path(executable: string) -> string { | Owns path semantics, traversal, or normalization. |
| 1014 | add_to_path | proc add_to_path(directory: string) -> int { | Owns path semantics, traversal, or normalization. |
| 1032 | remove_from_path | proc remove_from_path(directory: string) -> int { | Owns path semantics, traversal, or normalization. |
| 1051 | path_segments | proc path_segments(p: string) -> [string] { | Owns path semantics, traversal, or normalization. |
| 1055 | path_depth | proc path_depth(p: string) -> i32 { | Owns path semantics, traversal, or normalization. |
| 1059 | path_report | proc path_report(p: string) -> Path { | Owns path semantics, traversal, or normalization. |
Exports
| Line | Name | Signature | Role |
|---|---|---|---|
| 1066 | * | export * | Re-exports surfaces that the module wants to expose as part of its public boundary. |
Integration boundaries
Within path, this file should remain focused. If a future helper changes the host boundary, scheduling boundary, or data-shape boundary, it probably belongs in a neighbor module instead of being added here by convenience.
- Family responsibility: Path manipulation, special locations, walkers, and globbing.
- Family architecture role: Use `path` when the program needs path semantics, traversal, or normalization. Keep it distinct from file contents and from business validation.
Composition guidance
Choose this module when
- Choose
path.vitlwhen the main question is owned by this module rather than by transport, storage, orchestration, or user-interface code. - Use this module when bytes or paths cross a host boundary and architecture must keep that boundary visible.
- A project root can be normalized before any file is read.
- A walker can enumerate source files while parsing and diagnostics remain elsewhere.
Pause before extending it when
- Avoid extending this file when the new helper mostly changes the boundary to host I/O, runtime coordination, or foreign integration instead of staying inside
path. - Check nearby modules such as
path/globbing.vitl,path/manipulation.vitl,path/special.vitlbefore adding convenience wrappers here.
Relationship table
This table keeps the page closer to a real encyclopedia entry: a module is easier to understand when compared with its nearest alternatives in the same family.
| Neighbor | Procedures | Data surfaces | Why compare it |
|---|---|---|---|
path/globbing.vitl | 11 | 3 | Shares the same family boundary but carries a distinct slice of responsibility. |
path/manipulation.vitl | 40 | 4 | Shares the same family boundary but carries a distinct slice of responsibility. |
path/special.vitl | 19 | 3 | Shares the same family boundary but carries a distinct slice of responsibility. |
path/walker.vitl | 11 | 4 | Shares the same family boundary but carries a distinct slice of responsibility. |