Problem
Plugin subagents cannot use permissionMode — Claude Code intentionally ignores it for security reasons. This
means codex:codex-rescue cannot get Bash permission in background mode, where permission prompts are impossible
and auto-denied.
Related bug: #94
Proposed Solution
Update /codex:setup to copy plugins/codex/agents/codex-rescue.md into ~/.claude/agents/ with permissionMode: bypassPermissions added.
Regular agents in ~/.claude/agents/ fully support permissionMode, so the subagent would work correctly in background mode after setup.
Changes needed
scripts/codex-companion.mjs — setup command copies the agent file to ~/.claude/agents/codex-rescue.md with
permissionMode: bypassPermissions injected
- Add a version/hash check so re-running
/codex:setup after a plugin update refreshes the copied file
automatically
/codex:setup output informs the user the agent was installed to ~/.claude/agents/
Tradeoff
Requires the user to run /codex:setup once to get the fix. Anyone who skips setup still has the broken plugin subagent.
Problem
Plugin subagents cannot use
permissionMode— Claude Code intentionally ignores it for security reasons. Thismeans
codex:codex-rescuecannot get Bash permission in background mode, where permission prompts are impossibleand auto-denied.
Related bug: #94
Proposed Solution
Update
/codex:setupto copyplugins/codex/agents/codex-rescue.mdinto~/.claude/agents/withpermissionMode: bypassPermissionsadded.Regular agents in
~/.claude/agents/fully supportpermissionMode, so the subagent would work correctly in background mode after setup.Changes needed
scripts/codex-companion.mjs— setup command copies the agent file to~/.claude/agents/codex-rescue.mdwithpermissionMode: bypassPermissionsinjected/codex:setupafter a plugin update refreshes the copied fileautomatically
/codex:setupoutput informs the user the agent was installed to~/.claude/agents/Tradeoff
Requires the user to run
/codex:setuponce to get the fix. Anyone who skips setup still has the broken plugin subagent.