-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Milestone
Description
Summary
Add a minimal runtime I/O/process layer so command execution can be implemented as fallible builtins and composed in scripts.
Why
#19 (shell call syntax) needs a stable execution substrate first.
Today runtime context is stdout-only and there is no process execution primitive.
Scope (MVP)
- Extend runtime context to support both stdout and stderr writers
- Add internal process execution primitive:
- input: program + argv
- output:
{ code: Int, stdout: String, stderr: String } - fallible on spawn/wait failures
- Define minimal error enum for runtime I/O/process failures:
- e.g.
IoError { SpawnFailed, WaitFailed, NotFound, PermissionDenied }
- e.g.
- Expose builtins:
cmd(spec) -> IoError!RunResultshell(script: String) -> IoError!RunResult(explicit unsafe shell mode)
Out of Scope
- Async/background jobs
- Streaming stdout/stderr
- Env/cwd overrides per command
- Pipeline DSL (
pipe/run/check) sugar - File read/write builtins
Acceptance Criteria
- Running a known command returns exit code/stdout/stderr
- Unknown command returns an
IoErrorvariant - Non-zero process exit is represented in
RunResult.code(not a runtime crash) cmdandshellare both type-checkable as fallible functions- Basic tests cover success, failure-to-spawn, and non-zero exit
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels