docs: add Codex PreToolUse adapter guide#2068
Closed
xuegaoge wants to merge 1 commit into
Closed
Conversation
|
macos seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
7133be3 to
8501ab8
Compare
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
docs/usage/CODEX_PRETOOLUSE_ADAPTER.md, a focused guide for installing an optional Codex Desktop/CLIPreToolUseadapter.hooks/codex/README.mdas the hook-directory overview and links it to the new usage guide.rtk gainworks, and installs RTK only when missing or incorrect.Why
rtk init --codexcurrently gives Codex prompt-level awareness throughAGENTS.mdandRTK.md, but it does not provide a native Codex hook. The documented adapter lets Codex rewrite Bash commands at tool-call time while preserving normal pass-through behavior when RTK has no rewrite.Validation
git diff --check HEAD~1..HEAD.CODEX_HOMEand verified it remained idempotent with onePreToolUseentry.python3 -m py_compile.git statusrewrites tortk git status.