スキル一覧に戻る
asgeo1

codex

by asgeo1

3🍴 0📅 2026年1月15日
GitHubで見るManusで実行

SKILL.md


name: codex description: Use when the user asks to run Codex CLI (codex exec, codex resume) or references OpenAI Codex for code analysis, refactoring, or automated editing source: https://github.com/skills-directory/skill-codex (modified for explicit session IDs)

Codex Skill Guide

Running a Task

  1. Select the sandbox mode required for the task; default to --sandbox read-only unless edits or network access are necessary.

  2. Assemble the command with the appropriate options:

    • -m, --model <MODEL> - specify model (optional, uses default if omitted)
    • --config model_reasoning_effort="<xhigh|high|medium|low>" - reasoning effort (optional)
    • --sandbox <read-only|workspace-write|danger-full-access> - sandbox mode
    • --full-auto - auto-approve within sandbox
    • -C, --cd <DIR> - working directory
    • --skip-git-repo-check - always use this flag
    • --json - output JSONL (use when you need to capture session ID)
  3. IMPORTANT: By default, append 2>/dev/null to suppress thinking tokens (stderr). Only show stderr if debugging is needed.

  4. Run the command, capture stdout/stderr (filtered as appropriate), and summarize the outcome for the user.

  5. After Codex completes, inform the user: "You can resume this Codex session at any time by saying 'codex resume' or asking me to continue."

Quick Reference

Use caseKey flags
Read-only review/analysis--sandbox read-only --skip-git-repo-check 2>/dev/null
Apply local edits--sandbox workspace-write --full-auto --skip-git-repo-check 2>/dev/null
Full access--sandbox danger-full-access --full-auto --skip-git-repo-check 2>/dev/null
Resume latest sessionecho "prompt" | codex exec --skip-git-repo-check resume --last 2>/dev/null

Session Management

Resuming Latest Session

echo "continue prompt" | codex exec --skip-git-repo-check resume --last 2>/dev/null

This works well for sequential execution (including subagent contexts).

Resuming with Explicit Session ID (Advanced)

If you need explicit session IDs (e.g., multiple parallel Codex sessions):

# Get the most recent session ID from filesystem
SESSION_ID=$(ls -t ~/.codex/sessions/*/*/*/*.jsonl | head -1 | grep -oE '[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}')

# Resume with explicit ID
codex exec --skip-git-repo-check resume "$SESSION_ID" "continue prompt" 2>/dev/null

Following Up

  • After every codex command, capture or note the session ID for potential resumption.
  • When resuming, prefer explicit session IDs over --last for reliability.
  • The resumed session automatically uses the same model, reasoning effort, and sandbox mode from the original session.
  • Restate the chosen settings when proposing follow-up actions.

Error Handling

  • Stop and report failures whenever codex --version or a codex exec command exits non-zero; request direction before retrying.
  • Before using high-impact flags (--full-auto, --sandbox danger-full-access), ask the user for permission using AskUserQuestion unless already given.
  • When output includes warnings or partial results, summarize them and ask how to adjust using AskUserQuestion.

スコア

総合スコア

50/100

リポジトリの品質指標に基づく評価

SKILL.md

SKILL.mdファイルが含まれている

+20
LICENSE

ライセンスが設定されている

0/10
説明文

100文字以上の説明がある

0/10
人気

GitHub Stars 100以上

0/15
最近の活動

3ヶ月以内に更新がある

0/10
フォーク

10回以上フォークされている

0/5
Issue管理

オープンIssueが50未満

+5
言語

プログラミング言語が設定されている

+5
タグ

1つ以上のタグが設定されている

0/5

レビュー

💬

レビュー機能は近日公開予定です