Commit Graph

2 Commits

Author SHA1 Message Date
alan cedfc22e45 Pipeline runs use the workspace's directory environment
Resolve the run workspace's environment with workenv (direnv, parent
.envrc, mise; same account rule as Claude chats) at run start and resume,
and apply it to Pi stage processes, a per-environment Pipelines-owned
OpenCode stage service (keyed by a hash of the change, reused across runs,
idle ones stopped after PIPELINES_OPENCODE_STAGE_IDLE_TIMEOUT, revived per
registration), delivery-gate checks and merges, plain-stage opencode CLI
calls and file-change capture git reads. Record the directory, .envrc
files, sources and variable names (never values) on the run detail; a
blocked .envrc becomes a run warning.
2026-11-04 18:08:42 +00:00
alan b4382b08ad Apply the chat directory's environment and account to Claude Code chats
Claude Code chats now start with the chat directory's own environment:
direnv (allowed .envrc only, via direnv export json) and mise (mise env
--json), cached per directory and invalidated when config, watched files or
allow records change. A blocked .envrc is logged and shown in the chat as a
notice and never applied. When the directory chooses the Claude account
(CLAUDE_CONFIG_DIR, API key or token variables), the server's service token
and login-file fallbacks are skipped and inherited credentials dropped.
Transcripts in a directory's CLAUDE_CONFIG_DIR are found for history,
resume and after a restart. PWD is set to the chat directory.
2026-11-02 16:37:20 +00:00