Expand description
Executable discovery (spec §20): an explicit configured override, then the absolute entries of PATH.
Structs§
- Found
- A discovered executable.
Enums§
- Executable
Status - Where
agentsresolved an agent’s executable to (SP5a design §3). Each variant is a listed fact, not an error. - Hit 🔒
- What a
PATHdirectory holds for an agent. - Origin
- Where a discovered executable came from.
Constants§
- SHELL_
EXTENSIONS 🔒 - Extensions std would run through a shell or that need an interpreter: refused on every platform (spec §23.2, SP2 design §7.2).
Functions§
- discover
- Finds
nameforagent: theexplicitoverride when given, otherwise the first absolutePATHdirectory that holds it. A shell script or a Windows shim is refused with a hint namingconfig_file. - has_
shell_ 🔒extension - Whether the file name ends in a shell extension. Trailing spaces and dots are ignored first, because
Windows strips them when it opens or launches the path (
codex.cmdrunscodex.cmdthrough cmd.exe). - is_
executable 🔒 - not_
installed 🔒 - repository_
local - Finds
namethrough the RELATIVE entries ofpath_var, each resolved againstcwd, in order; the first native (or, on Windows, unsupported) form wins. Absolute entries are skipped. Never runs anything. - search_
dir 🔒 - search_
path 🔒 - unsupported 🔒