cmd: a command gets a context and its process's streams #3

Merged
mikluko merged 1 commit from cmd-process into main 2026-11-16 04:47:22 +00:00
Owner

A command now runs as func(ctx, args, process): process carries stdin, stdout, stderr, the environment and the directory; ctx ends on SIGINT and SIGTERM. Until now a command got stderr alone, which the stand-in gc (stdin and stdout) and the host (SIGTERM) cannot work with. No behaviour changes: every command still fails "not implemented".

It touches main.go, the seam roomcity-9a wires the server through, so it goes first and alone: spec-bb1.34 and spec-bb1.33 both build on it.

Verified: go vet ./..., go test ./....

A command now runs as `func(ctx, args, process)`: `process` carries stdin, stdout, stderr, the environment and the directory; `ctx` ends on SIGINT and SIGTERM. Until now a command got stderr alone, which the stand-in `gc` (stdin and stdout) and the host (SIGTERM) cannot work with. No behaviour changes: every command still fails "not implemented". It touches `main.go`, the seam roomcity-9a wires the server through, so it goes first and alone: spec-bb1.34 and spec-bb1.33 both build on it. Verified: `go vet ./...`, `go test ./...`.
cmd: a command gets a context and its process's streams
All checks were successful
image / image (pull_request) Successful in 5s
test / changelog (pull_request) Successful in 4s
test / go (pull_request) Successful in 26s
e7b2613ae9
The commands are to read stdin and write stdout (the stand-in gc), end
with SIGTERM (the host) and read the environment; each had only stderr.
The context ends on SIGINT and SIGTERM.

Assisted-By: Claude <noreply@anthropic.com>
mikluko deleted branch cmd-process 2026-11-16 04:47:22 +00:00
Commenting is not possible because the repository is archived.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
mikluko/roomcity!3
No description provided.