使用 App 命令
这篇整理 Codex App 中常用 commands、keyboard shortcuts、slash commands 和 deeplinks。
App commands、快捷键、slash commands 和 deeplinks 都可能随版本变化。这里讲使用方式和核验入口,不把完整快捷键表当长期事实。
这篇整理 Codex App 里的四类入口:command menu、keyboard shortcuts、slash commands 和 codex:// deeplinks。实际按键和可用命令以 App 内 command menu 和官方文档为准。
先记 4 类入口
Command menu
用 App 内命令面板查当前版本真正可用的命令和快捷键。
Keyboard shortcuts
常见动作包括打开设置、打开文件夹、切换侧边栏、切换 diff 和终端。
Slash commands
在 thread composer 输入 /,按当前环境和权限过滤可用命令。
Deeplinks
用 codex:// 打开设置、skills、automations、指定 thread 或新 thread。
Keyboard shortcuts
不要背完整快捷键表。先掌握这几类动作:
- General:打开命令面板、设置、文件夹、返回/前进、调整字号、切换侧边栏、diff panel 和 terminal。
- Thread:新建 thread、在线程内搜索、前后切换 thread、使用 dictation。
- Review:进入 code review、查看 diff、确认或拒绝变更。
- Terminal:打开终端、清屏、运行验证命令。
最可靠的核验方式是在 App 内打开 command menu,然后搜索动作名称。
斜杠命令
Slash commands 让你不离开 thread composer,就能控制 Codex。可用 commands 会随 environment 和 access 变化。
Use a slash command
使用方式:
- 在 thread composer 中输入
/。 - 从列表中选择 command,或者继续输入来过滤,例如
/status。
你也可以在 thread composer 中输入 $ 来显式调用 skills。详见 Skills。
Enabled skills 也会出现在 slash command list 中。
Available slash commands
常见命令类型:
/feedback:提交反馈,并按需包含日志。/mcp:查看 MCP server 连接状态。/plan-mode:切换多步规划模式。/review:进入 code review mode,审查未提交变更或与 base branch 对比。/status:查看 thread ID、context usage 和 rate limits。
Deeplinks
Codex App 注册了 codex:// URL scheme,因此链接可以直接打开 App 的指定区域。
常见 deeplink:
codex://settings:打开 Settings。codex://skills:打开 Skills。codex://automations:进入 automation create mode。codex://threads/<thread-id>:打开本地 thread,<thread-id>必须是 UUID。codex://new:新建 thread,可带prompt、originUrl、path。
new-thread deeplink 的参数规则:
prompt:设置 initial composer text。path:必须是 local directory 的 absolute path;有效时,这个 directory 会成为 new thread 的 active workspace。originUrl:尝试通过 Git remote URL 匹配当前 workspace roots。path和originUrl同时存在时,Codex 先解析path。
使用建议
- 需要精确快捷键时,在 App 内 command menu 查,不靠教程截图。
- 自动化或外部系统打开 Codex 时,优先用 deeplink;涉及路径时只传本机真实绝对路径。
- 提供给团队的文档不要写“完整命令表”,写任务场景和官方核验入口。
- slash commands 和 enabled skills 受环境影响,团队环境要单独验收。