Shell Command Projection Module (expanded glossary entry, 2026-05-13)
Module owning all OS-facing I/O for the tool: runtime-aware command-text rendering (hook commands, PATH action lines, shim scripts), subprocess dispatch (run-git, run-npm, run-tool, probeTty), and platform file I/O (platformWriteSync, platformReadSync, platformEnsureDir). Single seam for platform-conditional logic — one place to fix any shell or file write regression across Windows, macOS, and Linux. Lives in get-shit-done/bin/lib/shell-command-projection.cjs. See ADR-0009 (superseded "does not execute" constraint) and ADR-0010 (superseded File Operation Engine).
Invariants:
- Result shape: all run-* return
\{ exitCode, stdout, stderr \}; never throw on non-zero exit code. - Platform policy owned at the seam:
shell: process.platform === 'win32'lives only in run-npm; probeTty returnsnullon Windows. - Normalization policy: platformWriteSync owns full
normalizeMdfor.md; CRLF-to-LF + trailing newline for all others; callers must NOT pre-callnormalizeMd. _normalizeMdis re-implemented inline (not imported fromcore.cjs) to avoid circular dep.atomicWriteFileSync,safeReadFile,normalizeMdremain incore.cjsexports until Phase 4 (#3468).
Migration plan: Phase 1 (#3465) seam additions complete; Phase 2 (#3466) targets 6 subprocess files; Phase 3 (#3467) targets 15 fs files (215 call sites); Phase 4 (#3468) removes compat exports.