core-agent-ide/codex-rs
dependabot[bot] be022be381
chore(deps): bump regex from 1.11.1 to 1.12.2 in /codex-rs (#7222)
Bumps [regex](https://github.com/rust-lang/regex) from 1.11.1 to 1.12.2.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/regex/blob/master/CHANGELOG.md">regex's
changelog</a>.</em></p>
<blockquote>
<h1>1.12.2 (2025-10-13)</h1>
<p>This release fixes a <code>cargo doc</code> breakage on nightly when
<code>--cfg docsrs</code> is
enabled. This caused documentation to fail to build on docs.rs.</p>
<p>Bug fixes:</p>
<ul>
<li>[BUG <a
href="https://redirect.github.com/rust-lang/regex/issues/1305">#1305</a>](<a
href="https://redirect.github.com/rust-lang/regex/issues/1305">rust-lang/regex#1305</a>):
Switches the <code>doc_auto_cfg</code> feature to <code>doc_cfg</code>
on nightly for docs.rs builds.</li>
</ul>
<h1>1.12.1 (2025-10-10)</h1>
<p>This release makes a bug fix in the new
<code>regex::Captures::get_match</code> API
introduced in <code>1.12.0</code>. There was an oversight with the
lifetime parameter
for the <code>Match</code> returned. This is technically a breaking
change, but given
that it was caught almost immediately and I've yanked the
<code>1.12.0</code> release,
I think this is fine.</p>
<h1>1.12.0 (2025-10-10)</h1>
<p>This release contains a smattering of bug fixes, a fix for excessive
memory
consumption in some cases and a new
<code>regex::Captures::get_match</code> API.</p>
<p>Improvements:</p>
<ul>
<li>[FEATURE <a
href="https://redirect.github.com/rust-lang/regex/issues/1146">#1146</a>](<a
href="https://redirect.github.com/rust-lang/regex/issues/1146">rust-lang/regex#1146</a>):
Add <code>Capture::get_match</code> for returning the overall match
without <code>unwrap()</code>.</li>
</ul>
<p>Bug fixes:</p>
<ul>
<li>[BUG <a
href="https://redirect.github.com/rust-lang/regex/issues/1083">#1083</a>](<a
href="https://redirect.github.com/rust-lang/regex/issues/1083">rust-lang/regex#1083</a>):
Fixes a panic in the lazy DFA (can only occur for especially large
regexes).</li>
<li>[BUG <a
href="https://redirect.github.com/rust-lang/regex/issues/1116">#1116</a>](<a
href="https://redirect.github.com/rust-lang/regex/issues/1116">rust-lang/regex#1116</a>):
Fixes a memory usage regression for large regexes (introduced in
<code>regex 1.9</code>).</li>
<li>[BUG <a
href="https://redirect.github.com/rust-lang/regex/issues/1195">#1195</a>](<a
href="https://redirect.github.com/rust-lang/regex/issues/1195">rust-lang/regex#1195</a>):
Fix universal start states in sparse DFA.</li>
<li>[BUG <a
href="https://redirect.github.com/rust-lang/regex/issues/1295">#1295</a>](<a
href="https://redirect.github.com/rust-lang/regex/pull/1295">rust-lang/regex#1295</a>):
Fixes a panic when deserializing a corrupted dense DFA.</li>
<li><a
href="8f5d9479d0">BUG
8f5d9479</a>:
Make <code>regex_automata::meta::Regex::find</code> consistently return
<code>None</code> when
<code>WhichCaptures::None</code> is used.</li>
</ul>
<h1>1.11.3 (2025-09-25)</h1>
<p>This is a small patch release with an improvement in memory usage in
some
cases.</p>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="5ea3eb1e95"><code>5ea3eb1</code></a>
1.12.2</li>
<li><a
href="ab0b07171b"><code>ab0b071</code></a>
regex-automata-0.4.13</li>
<li><a
href="691d51457d"><code>691d514</code></a>
regex-syntax-0.8.8</li>
<li><a
href="1dd9077779"><code>1dd9077</code></a>
docs: swap <code>doc_auto_cfg</code> with <code>doc_cfg</code></li>
<li><a
href="0089034cb3"><code>0089034</code></a>
regex-cli-0.2.3</li>
<li><a
href="140f8949da"><code>140f894</code></a>
regex-lite-0.1.8</li>
<li><a
href="27d6d65263"><code>27d6d65</code></a>
1.12.1</li>
<li><a
href="85398ad500"><code>85398ad</code></a>
changelog: 1.12.1</li>
<li><a
href="764efbd305"><code>764efbd</code></a>
api: tweak the lifetime of <code>Captures::get_match</code></li>
<li><a
href="ee6aa55e01"><code>ee6aa55</code></a>
rure-0.2.4</li>
<li>Additional commits viewable in <a
href="https://github.com/rust-lang/regex/compare/1.11.1...1.12.2">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=regex&package-manager=cargo&previous-version=1.11.1&new-version=1.12.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-24 11:43:57 -08:00
..
.cargo build: 8mb stacks on win (#5997) 2025-10-30 16:12:50 -07:00
.config fix flaky test: approval_matrix_covers_all_modes (#7028) 2025-11-20 14:37:42 -08:00
ansi-escape Fix transcript mode rendering issue when showing tab chars (#4911) 2025-10-08 11:42:09 -07:00
app-server fix(windows) support apply_patch parsing in powershell (#7221) 2025-11-24 19:32:47 +00:00
app-server-protocol [app-server] feat: expose gitInfo/cwd/etc. on Thread (#7060) 2025-11-21 10:37:12 -08:00
app-server-test-client [app-server] feat: v2 apply_patch approval flow (#6760) 2025-11-19 20:13:31 -08:00
apply-patch fix(windows) support apply_patch parsing in powershell (#7221) 2025-11-24 19:32:47 +00:00
arg0 Use codex-linux-sandbox in unified exec (#6480) 2025-11-10 17:17:09 -08:00
async-utils Support graceful agent interruption (#5287) 2025-10-17 18:52:57 +00:00
backend-client storing credits (#6858) 2025-11-19 10:49:35 -08:00
chatgpt chore: merge git crates (#5909) 2025-10-29 12:11:44 +00:00
cli execpolicycheck command in codex cli (#7012) 2025-11-20 16:44:31 -05:00
cloud-tasks Add test timeout (#6612) 2025-11-14 09:30:37 -08:00
cloud-tasks-client chore(deps): bump thiserror from 2.0.16 to 2.0.17 in /codex-rs (#4426) 2025-10-30 19:00:00 -07:00
codex-backend-openapi-models update credit status details (#6862) 2025-11-19 01:40:22 +00:00
common Fix/correct reasoning display (#6749) 2025-11-19 15:52:24 -08:00
core fix(windows) support apply_patch parsing in powershell (#7221) 2025-11-24 19:32:47 +00:00
docs Revert "[core] add optional status_code to error events (#6865)" (#6955) 2025-11-20 01:26:14 +00:00
exec support MCP elicitations (#6947) 2025-11-21 14:44:53 -08:00
exec-server feat: declare server capability in shell-tool-mcp (#7112) 2025-11-21 16:11:01 -08:00
execpolicy execpolicycheck command in codex cli (#7012) 2025-11-20 16:44:31 -05:00
execpolicy-legacy migrating execpolicy -> execpolicy-legacy and execpolicy2 -> execpolicy (#6956) 2025-11-19 19:14:10 -08:00
feedback [feedback] Add source info into feedback metadata. (#7140) 2025-11-24 19:05:37 +00:00
file-search Follow symlinks during file search (#4453) 2025-11-03 20:28:33 -08:00
keyring-store Fix FreeBSD/OpenBSD builds: target-specific keyring features and BSD hardening (#6680) 2025-11-17 05:07:34 +00:00
linux-sandbox refactor: inline sandbox type lookup in process_exec_tool_call (#7122) 2025-11-21 22:53:05 +00:00
lmstudio LM Studio OSS Support (#2312) 2025-11-17 11:49:09 -08:00
login [Auth] Choose which auth storage to use based on config (#5792) 2025-10-27 19:41:49 -07:00
mcp-server support MCP elicitations (#6947) 2025-11-21 14:44:53 -08:00
mcp-types [app-server] remove serde(skip_serializing_if = "Option::is_none") annotations (#5939) 2025-10-30 18:18:53 +00:00
ollama LM Studio OSS Support (#2312) 2025-11-17 11:49:09 -08:00
otel chore: drop model_max_output_tokens (#7100) 2025-11-21 17:42:54 +00:00
process-hardening Fix FreeBSD/OpenBSD builds: target-specific keyring features and BSD hardening (#6680) 2025-11-17 05:07:34 +00:00
protocol [feedback] Add source info into feedback metadata. (#7140) 2025-11-24 19:05:37 +00:00
responses-api-proxy feat: add options to responses-api-proxy to support Azure (#6129) 2025-11-03 10:06:00 -08:00
rmcp-client feat: declare server capability in shell-tool-mcp (#7112) 2025-11-21 16:11:01 -08:00
scripts fix(scripts) next_minor_version should reset patch number (#7050) 2025-11-21 10:17:12 -08:00
stdio-to-uds feat: experimental codex stdio-to-uds subcommand (#5350) 2025-10-19 21:12:45 -07:00
tui [feedback] Add source info into feedback metadata. (#7140) 2025-11-24 19:05:37 +00:00
utils Delete tiktoken-rs (#7018) 2025-11-20 11:15:04 -08:00
windows-sandbox-rs consolidate world-writable-directories scanning. (#7234) 2025-11-24 09:51:58 -08:00
.gitignore [MCP] Prefix MCP tools names with mcp__ (#5309) 2025-10-19 20:41:55 -04:00
Cargo.lock chore(deps): bump regex from 1.11.1 to 1.12.2 in /codex-rs (#7222) 2025-11-24 11:43:57 -08:00
Cargo.toml chore(deps): bump regex from 1.11.1 to 1.12.2 in /codex-rs (#7222) 2025-11-24 11:43:57 -08:00
clippy.toml fix: switch rate limit reset handling to timestamps (#5304) 2025-10-17 17:39:37 -07:00
code Send text parameter for non-gpt-5 models (#4195) 2025-09-24 22:00:06 +00:00
config.md Fix link to MCP Servers config section (#5301) 2025-10-17 14:58:27 -07:00
default.nix Fix nix build (#6230) 2025-11-04 17:07:37 -08:00
justfile feat: add app-server-test-client crate for internal use (#5391) 2025-11-14 12:39:58 -08:00
README.md add codex debug seatbelt --log-denials (#4098) 2025-11-10 22:48:14 +00:00
rust-toolchain.toml chore: upgrade to Rust 1.90 (#4124) 2025-09-24 08:32:00 -07:00
rustfmt.toml Update cargo to 2024 edition (#842) 2025-05-07 08:37:48 -07:00

Codex CLI (Rust Implementation)

We provide Codex CLI as a standalone, native executable to ensure a zero-dependency install.

Installing Codex

Today, the easiest way to install Codex is via npm:

npm i -g @openai/codex
codex

You can also install via Homebrew (brew install --cask codex) or download a platform-specific release directly from our GitHub Releases.

Documentation quickstart

What's new in the Rust CLI

The Rust implementation is now the maintained Codex CLI and serves as the default experience. It includes a number of features that the legacy TypeScript CLI never supported.

Config

Codex supports a rich set of configuration options. Note that the Rust CLI uses config.toml instead of config.json. See docs/config.md for details.

Model Context Protocol Support

MCP client

Codex CLI functions as an MCP client that allows the Codex CLI and IDE extension to connect to MCP servers on startup. See the configuration documentation for details.

MCP server (experimental)

Codex can be launched as an MCP server by running codex mcp-server. This allows other MCP clients to use Codex as a tool for another agent.

Use the @modelcontextprotocol/inspector to try it out:

npx @modelcontextprotocol/inspector codex mcp-server

Use codex mcp to add/list/get/remove MCP server launchers defined in config.toml, and codex mcp-server to run the MCP server directly.

Notifications

You can enable notifications by configuring a script that is run whenever the agent finishes a turn. The notify documentation includes a detailed example that explains how to get desktop notifications via terminal-notifier on macOS.

codex exec to run Codex programmatically/non-interactively

To run Codex non-interactively, run codex exec PROMPT (you can also pass the prompt via stdin) and Codex will work on your task until it decides that it is done and exits. Output is printed to the terminal directly. You can set the RUST_LOG environment variable to see more about what's going on.

Experimenting with the Codex Sandbox

To test to see what happens when a command is run under the sandbox provided by Codex, we provide the following subcommands in Codex CLI:

# macOS
codex sandbox macos [--full-auto] [--log-denials] [COMMAND]...

# Linux
codex sandbox linux [--full-auto] [COMMAND]...

# Windows
codex sandbox windows [--full-auto] [COMMAND]...

# Legacy aliases
codex debug seatbelt [--full-auto] [--log-denials] [COMMAND]...
codex debug landlock [--full-auto] [COMMAND]...

Selecting a sandbox policy via --sandbox

The Rust CLI exposes a dedicated --sandbox (-s) flag that lets you pick the sandbox policy without having to reach for the generic -c/--config option:

# Run Codex with the default, read-only sandbox
codex --sandbox read-only

# Allow the agent to write within the current workspace while still blocking network access
codex --sandbox workspace-write

# Danger! Disable sandboxing entirely (only do this if you are already running in a container or other isolated env)
codex --sandbox danger-full-access

The same setting can be persisted in ~/.codex/config.toml via the top-level sandbox_mode = "MODE" key, e.g. sandbox_mode = "workspace-write".

Code Organization

This folder is the root of a Cargo workspace. It contains quite a bit of experimental code, but here are the key crates:

  • core/ contains the business logic for Codex. Ultimately, we hope this to be a library crate that is generally useful for building other Rust/native applications that use Codex.
  • exec/ "headless" CLI for use in automation.
  • tui/ CLI that launches a fullscreen TUI built with Ratatui.
  • cli/ CLI multitool that provides the aforementioned CLIs via subcommands.