Repository navigation
Releases
1.2.1
A correction to 1.2.0, which said that the hook-untrusted line "the bypass flag also runs the hooks of a project that is not trusted" was this tool's error on every version.
- It was right in one case: before Codex 0.169.0 a run with
sandbox_mode = "danger-full-access"trusted the folder first (it wrote the entry itself), and with--dangerously-bypass-hook-trustthe project's.codex/hooks.jsonthen ran in the same session (SessionStart and PreToolUse, put to 0.166.0 and 0.168.0). In the default sandbox those hooks never ran, which is all the check of 1.2.0 tried. - The explain page and the README say both, and the real-binary check now covers the danger-full-access run on either side of 0.169.0: since that version no run trusts a folder by itself, so the hooks do not run. Found by everyhook's bisect of the same Codex change. Closes #5.
The good first issue is still #4: why --file -, which reads the commands from standard input.
See the README to use it, and CHANGELOG.md for every version.
1.2.0
Following Codex 0.167.0 to 0.170.0, whose changes turned the weekly real-binary checks red from 9 November. Each change was bisected with side-by-side installs of 0.166.0, 0.167.0, 0.168.0, 0.169.0 and 0.170.0, and every check is put to 0.170.0 on Linux, macOS and Windows.
costhas a new row, Deferred tool namespaces. Since Codex 0.167.0 the description oftool_searchno longer names the sources of deferred tools; a<tools>block of the developer message does:multi_agent_v1, andmcp__<id>for each MCP server that starts (every character of the id other than a letter, a digit or_becomes_). The tool definitions no longer count a server's id intool_search, and the block is reproduced character for character.- The recorded figures of the first request come from Codex 0.170.0 on all three systems:
tool_search699 characters (was 804),view_image371 (was 526; itsdetailparameter went in 0.168.0), and the new text of the bundledopenai-docsskill (0.169.0). The base instructions, the permissions and environment blocks, the MCP resource tools and theweb_searchsizes did not move. - Trust, after Codex 0.169.0 (openai/codex#60041): in a folder that is not trusted,
codex execnow prints a warning namingcodex exec --trust;codex exec --trustwrites the Git root's entry and loads the project's file in the same run; an entry marked untrusted stops it; and no sandbox mode trusts a folder any more (before 0.169.0,danger-full-accessdid).lint'suntrusted-projectfinding, its fix and the explain pages ofuntrusted-project,toml-errorandtrust-key-spellingsay so. hook-untrusted: corrected in 1.2.1. Before Codex 0.169.0 the bypass flag did run an untrusted project's hooks in a run withdanger-full-access, which trusted the folder first; this release had called the old line wrong on every version (#5).
The good first issue is still #4: why --file -, which reads the commands from standard input.
See the README to use it, and CHANGELOG.md for every version.
1.1.0
why --file <list>judges many commands at once: one command per line of a file, one verdict for each, in the order of the file, with a summary count. Blank lines and lines that start with#are skipped, CRLF files work, and--project,--profileand--shellapply to every line. Exit 1 if Codex would refuse any of them. With--jsonit prints one document: the fields that do not depend on the command once, andresults, thewhydocument of each command. A file that cannot be read, a file with no command in it, and--filetogether with a command are usage errors (exit 2).- Contributed by @yoreva-01 in #2, for the good first issue #1. The pull request's tests ran on Linux, macOS and Windows, and its real-binary checks passed against Codex 0.165.0 on all three, before the merge.
The next good first issue is #4: why --file -, which reads the commands from standard input, so history | cut -c8- | sort -u | codex-config-doctor why --file - needs no file in between.
See the README to use it, and CHANGELOG.md for every version.
1.0.0
- First release. A command line tool that reads a Codex CLI configuration and says what Codex will do with it. It changes nothing, starts no program and opens no connection. Six commands:
show,lint,why,agents,costandexplain, each with--json;--projectand--profileon the five that read the configuration. showprints every layer Codex loads for the project in the order it applies them (system, user, profile, and the project's.codex/config.tomlfrom the project root down to the working folder), each read, missing, skipped or broken; the merged settings with the layer each came from; the keys a project may not set; the AGENTS.md files againstproject_doc_max_bytes; the rules; the hooks and whether Codex trusts them; the MCP servers; the model provider; and the Windows sandbox.linthas 44 findings, each with a severity, the file and line, what Codex does about it and the fix; 42 rest on the binary and two on the documentation.lint --markdownis the short form to paste into an agent (at most 12 findings, 500 characters a line).why "<command>"says whether Codex runs a shell command inside the sandbox, outside it through an allow rule, asks first, or refuses it, which rule matched each part, and how a script is split into the commands Codex judges.agentslists the AGENTS.md files as Codex reads them (included, cut, left out) and--printprints the message exactly as Codex builds it.costadds up what the first request of a session carries before your words.explain <id>andexplain --listgive the page of a finding, each line marked verified, documented or not verified.- What Codex does is what the real binary did. Codex 0.163.0 was put to the TOML reader (128 files), the keys of
config.toml(321 keys, 21 typos, 198 values of the wrong type), the layers (19 worlds), the AGENTS.md message (44 worlds), the rules (327 commands and 63 files forcodex execpolicy check), the hooks (41 worlds and the trust hash), every banned rule prefix (88), and the first request. The answers are recorded intest/fixtures/and the unit tests hold the code to them without Codex;test/e2e-*.test.mjsask Codex again, and CI runs them on Ubuntu, macOS and Windows against the npm release of Codex. - Found on the way, and written in the pages of
explainand in whatwhysays:codex execwithsandbox_mode = "danger-full-access"(and withworkspace-writeon Linux and macOS) writes a trusted entry for the working folder into yourconfig.toml; a command that no rule decides but that Codex finds dangerous (rmwith a force option, wherever it is in a script; in PowerShellRemove-Item -Force) asks, and is refused withapproval_policy = "never", whilegit resetandgit rmrun;~/.agents/skillsis read on Linux and macOS;features.prefer_mxcselects no sandbox where MXC is not available, as on Windows Server 2025; a rules file with an error stopscodex execbut only warns the terminal UI, which then applies none of your rules; an allow rule forgit,rm,env,sudo, a shell or an interpreter alone, and fornpm run, is ignored; an enabled MCP server brings three tools to every request and its own tools are deferred; the lower-case path in Codex's own trust warning is the spelling that works on Windows, and forward slashes are not. - Zero tokens for the tool.
lint --markdownputs at most the number of characters the README states in front of a model, and only if you paste it.