From 2cbe36b532ffce9db3ee03474924936f1531766a Mon Sep 17 00:00:00 2001 From: cexll Date: Wed, 19 Nov 2025 23:06:37 +0800 Subject: [PATCH] fix codex skill --- skills/codex/SKILL.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/skills/codex/SKILL.md b/skills/codex/SKILL.md index 273d2d1..bb5698e 100644 --- a/skills/codex/SKILL.md +++ b/skills/codex/SKILL.md @@ -23,6 +23,8 @@ Execute Codex CLI commands and parse structured JSON responses. Supports file re uv run ~/.claude/skills/codex/scripts/codex.py "" [model] [working_dir] ``` +**Foreground only (no background/BashOutput)**: Never set `background: true`, never accept Claude's “Running in the background” mode, and avoid `BashOutput` streaming loops. Keep a single foreground Bash call per Codex task; if work might be long, split it into smaller foreground runs instead of offloading to background execution. + **Optional methods** (direct execution or via Python): ```bash ~/.claude/skills/codex/scripts/codex.py "" [model] [working_dir] @@ -66,6 +68,8 @@ Error format (stderr): ERROR: Error message ``` +Return only the final agent message and session ID—do not paste raw `BashOutput` logs or background-task chatter into the conversation. + ### Invocation Pattern All automated executions may only invoke `uv run ~/.claude/skills/codex/scripts/codex.py "" ...` through the Bash tool in the foreground, and the `timeout` must remain fixed at `7200000` (non-negotiable):