From 001a342f20fe75b7cc1b4d7f7e7a525e849fc6d4 Mon Sep 17 00:00:00 2001 From: Peter Steinberger Date: Fri, 2 Jan 2026 23:56:01 +0000 Subject: [PATCH] coding-agent: workdir pattern + patience rules - Use bash workdir param so Codex wakes up in a 'little box' - Prevents reading unrelated files (like my soul.md lol) - Added rule: NEVER offer to build it yourself when user asks for Codex - gpt-5.2-codex requires medium reasoning effort --- skills/coding-agent/SKILL.md | 53 ++++++++++++++++++++++++++++++------ 1 file changed, 45 insertions(+), 8 deletions(-) diff --git a/skills/coding-agent/SKILL.md b/skills/coding-agent/SKILL.md index 3e545ec81..2b0654de5 100644 --- a/skills/coding-agent/SKILL.md +++ b/skills/coding-agent/SKILL.md @@ -40,20 +40,47 @@ Interactive (preferred in tmux): ## Codex CLI -One-shot (safe in tmux): -- `codex exec "Write a Python function that ..."` -- `codex exec --model gpt-4o "Complex task"` -- `codex exec --model o3 "Reasoning-heavy task"` +⚠️ **Model-specific settings required!** -Interactive: +| Model | Config Needed | +|-------|---------------| +| `gpt-4o` | Works with defaults | +| `gpt-5.2-codex` | Requires `-c reasoning_effort="medium"` (NOT low/high!) | +| `o3` | ❌ Not available with ChatGPT accounts | + +**One-shot with tmux (recommended):** +```bash +# IMPORTANT: Use bash workdir param to start in the target folder! +# This way Codex "wakes up in a little box" - only sees relevant files + +# Default model (gpt-4o) +bash workdir:~/project/folder command:"tmux new -d -s codex-task 'codex exec \"Your task\"'" + +# gpt-5.2-codex (MUST use medium reasoning) +bash workdir:~/project/folder command:"tmux new -d -s codex-task 'codex exec --model gpt-5.2-codex -c reasoning_effort=\"medium\" \"Your task\"'" + +# Full auto mode (sandboxed, auto-approve) +bash workdir:~/project/folder command:"tmux new -d -s codex-task 'codex exec --full-auto \"Your task\"'" + +# Monitor progress +tmux capture-pane -t codex-task -p | tail -20 +``` + +**Interactive:** - `codex "Your prompt"` - `codex resume` - `codex resume --last` - `codex resume --session ` -Apply changes: +**Apply changes:** - `codex apply` +**Useful flags:** +- `-s workspace-write` — Allow writing to workspace +- `--full-auto` — Sandboxed + auto-approve +- `-C ` — Set working directory +- `--skip-git-repo-check` — Run outside git repos + ## OpenCode One-shot: @@ -74,5 +101,15 @@ Session management: ## Notes -- Prefer **tmux** even for one-shot runs; keep history + recovery. -- For auth, run the tool’s login flow in tmux (`claude`, `codex login`, `opencode auth`). +- **Always prefer tmux** — keeps history, survives disconnects, allows monitoring +- For auth: `claude`, `codex login`, `opencode auth` +- Check tmux session: `tmux attach -t ` +- List sessions: `tmux list-sessions` + +## ⚠️ IMPORTANT: Respect Tool Choice! + +**If user asks for Codex/Claude Code/OpenCode → USE THAT TOOL!** +- NEVER offer to "just build it yourself" instead +- NEVER kill a running session because it's "too slow" +- Let the tool complete its work — be patient! +- The user wants to test/use that specific tool for a reason