Install
1
Install the plugin
$
npx claudepluginhub kazuph/dotfiles --plugin kazuph-dotfiles

Want just this skill?

Add to a custom plugin, then install with one command.

Description

Codex CLI (GPT-5) を使って調査・実装・レビューを実行する。「codexで調べて」「codexに実装させて」「codexでレビュー」等で自動発動。

Tool Access

This skill is limited to using the following tools:

BashReadGlobGrep
Skill Content

Codex Skill

Codex CLI を使って3種類のタスクを実行する統合スキル。

共通ルール

  • TTY必須: 全コマンドを script -q /dev/null でラップ(ないと tcgetattr エラー)
  • モデル固定: exec-m gpt-5.3-codex-sparkreview-c model="gpt-5.3-codex-spark" を指定(reviewに -m フラグはない)
  • サンドボックス: --sandbox workspace-write --config sandbox_workspace_write.network_access=true --dangerously-bypass-approvals-and-sandbox
  • 出力抑制(exec系): >/dev/null 2>&1 + -o "$outfile" で最終メッセージのみ取得(トークン節約)

共通プレフィックス

以下を CODEX_BASE として全コマンドに付ける:

CODEX_BASE="codex --sandbox workspace-write --config sandbox_workspace_write.network_access=true --dangerously-bypass-approvals-and-sandbox"

1. 調査 (investigate)

コードベースの調査・分析。読み取り専用(--full-auto なし)。

コマンド

outfile=$(mktemp -t codex)
script -q /dev/null codex \
  --sandbox workspace-write \
  --config sandbox_workspace_write.network_access=true \
  --dangerously-bypass-approvals-and-sandbox \
  exec --skip-git-repo-check -m gpt-5.3-codex-spark -o "$outfile" \
  "<プロンプト>" >/dev/null 2>&1
cat "$outfile"

ディレクトリ指定あり

outfile=$(mktemp -t codex)
script -q /dev/null codex \
  --sandbox workspace-write \
  --config sandbox_workspace_write.network_access=true \
  --dangerously-bypass-approvals-and-sandbox \
  exec --skip-git-repo-check -m gpt-5.3-codex-spark -C /path/to/dir -o "$outfile" \
  "<プロンプト>" >/dev/null 2>&1
cat "$outfile"

ポイント

  • --full-auto を付けない → ファイル変更なし
  • 調査プロンプトには「ファイルの変更は行わないでください」を明記

2. 実装 (implement)

コードの実装・修正。書き込み有効(--full-auto 付き)。

コマンド

outfile=$(mktemp -t codex)
script -q /dev/null codex \
  --sandbox workspace-write \
  --config sandbox_workspace_write.network_access=true \
  --dangerously-bypass-approvals-and-sandbox \
  exec --skip-git-repo-check --full-auto -m gpt-5.3-codex-spark -o "$outfile" \
  "<プロンプト>" >/dev/null 2>&1
cat "$outfile"

ディレクトリ指定あり

outfile=$(mktemp -t codex)
script -q /dev/null codex \
  --sandbox workspace-write \
  --config sandbox_workspace_write.network_access=true \
  --dangerously-bypass-approvals-and-sandbox \
  exec --skip-git-repo-check --full-auto -m gpt-5.3-codex-spark -C /path/to/dir -o "$outfile" \
  "<プロンプト>" >/dev/null 2>&1
cat "$outfile"

ポイント

  • --full-auto でファイル作成・編集・削除を許可
  • 実行前にユーザーに方針確認、実行後に git diff で変更確認
  • タイムアウト: 長いタスクは timeout 600 でガード

3. レビュー (review)

コードレビュー。codex review サブコマンドを使用。

未コミット変更のレビュー

script -q /dev/null codex \
  --sandbox workspace-write \
  --config sandbox_workspace_write.network_access=true \
  --dangerously-bypass-approvals-and-sandbox \
  review --uncommitted -c model="gpt-5.3-codex-spark" 2>&1

ブランチ差分のレビュー

script -q /dev/null codex \
  --sandbox workspace-write \
  --config sandbox_workspace_write.network_access=true \
  --dangerously-bypass-approvals-and-sandbox \
  review --base develop -c model="gpt-5.3-codex-spark" 2>&1

特定コミットのレビュー

script -q /dev/null codex \
  --sandbox workspace-write \
  --config sandbox_workspace_write.network_access=true \
  --dangerously-bypass-approvals-and-sandbox \
  review --commit <SHA> -c model="gpt-5.3-codex-spark" 2>&1

カスタム観点でレビュー

script -q /dev/null codex \
  --sandbox workspace-write \
  --config sandbox_workspace_write.network_access=true \
  --dangerously-bypass-approvals-and-sandbox \
  review --uncommitted -m gpt-5.3-codex-spark \
  "セキュリティ観点でレビュー。XSS、SQLi、認証バイパスを重点確認" 2>&1

ディレクトリ指定あり

script -q /dev/null codex \
  --sandbox workspace-write \
  --config sandbox_workspace_write.network_access=true \
  --dangerously-bypass-approvals-and-sandbox \
  -C /path/to/dir \
  review --base develop -c model="gpt-5.3-codex-spark" 2>&1

ポイント

  • exec ではなく review サブコマンドを使う
  • review は読み取り専用(コード変更なし)
  • 出力はレビューコメントそのものなので -o 不要、2>&1 で直接取得
  • ソース指定(--uncommitted / --base / --commit)はカスタムプロンプトと併用不可。カスタム観点でレビューする場合はソース指定なしで [PROMPT] のみ渡す
  • モデル指定は -c model="gpt-5.3-codex-spark"-m フラグは review サブコマンドにはない)

引数パターン

呼び出し動作
/codex investigate <prompt>読み取り調査
/codex implement <prompt>書き込み実装
/codex review未コミット変更レビュー
/codex review --base developブランチ差分レビュー

引数の最初の語が investigate / implement / review でモードを判別する。

トラブルシューティング

  • TTYエラー: script -q /dev/null を付け忘れていないか
  • Codex unreachable: codex --version で CLI 確認
  • タイムアウト: スコープを絞って再実行
  • 意図しない変更(implement): git checkout -- . でリセット(確認後)
Stats
Stars15
Forks2
Last CommitFeb 14, 2026
Actions

Similar Skills

cache-components

Expert guidance for Next.js Cache Components and Partial Prerendering (PPR). **PROACTIVE ACTIVATION**: Use this skill automatically when working in Next.js projects that have `cacheComponents: true` in their next.config.ts/next.config.js. When this config is detected, proactively apply Cache Components patterns and best practices to all React Server Component implementations. **DETECTION**: At the start of a session in a Next.js project, check for `cacheComponents: true` in next.config. If enabled, this skill's patterns should guide all component authoring, data fetching, and caching decisions. **USE CASES**: Implementing 'use cache' directive, configuring cache lifetimes with cacheLife(), tagging cached data with cacheTag(), invalidating caches with updateTag()/revalidateTag(), optimizing static vs dynamic content boundaries, debugging cache issues, and reviewing Cache Component implementations.

138.4k