From 83c74125bcaff2cc63d6cadd2917e9783c19b1ec Mon Sep 17 00:00:00 2001 From: jif-oai Date: Sat, 7 Feb 2026 17:36:44 +0100 Subject: [PATCH] Bootstrap shell commands via user shell snapshot (#10909) Summary - wrap `shell -lc` executions that use a snapshot with the session shell so the saved environment is sourced before delegating to the original shell - escape single quotes in the generated wrapper and add tests covering Bash/Zsh/sh session bootstrapping Testing - Not run (not requested) --- codex-rs/core/src/tools/runtimes/mod.rs | 153 ++++++++++++++++++++++-- 1 file changed, 146 insertions(+), 7 deletions(-) diff --git a/codex-rs/core/src/tools/runtimes/mod.rs b/codex-rs/core/src/tools/runtimes/mod.rs index ddf367178..8e4c47722 100644 --- a/codex-rs/core/src/tools/runtimes/mod.rs +++ b/codex-rs/core/src/tools/runtimes/mod.rs @@ -47,9 +47,10 @@ pub(crate) fn build_command_spec( /// the original script: /// /// shell -lc "