Code Reviewer for Codex
Review your SCM diffs with OpenAI Codex by right-clicking a changed file.
Supports both Git and SVN repositories.
Features
- Context Menu Integration: Right-click any file in the SCM view and select Review with Codex to request a code review instantly
- Live Review Tab: Opens a dedicated tab in the current editor group and appends Codex JSONL events as they arrive
- Automatic Codex Execution: Runs the review with the CLI bundled with the official Codex extension in a read-only sandbox
- Concurrent Reviews: Runs each review in its own tab and CLI process, so multiple reviews can progress independently
- Multi-Selection Support: Select multiple files and request a batch review in one action
- GitHub Pull Request Panel Integration: Adds a separate Review Changed Files with Codex action for reviewing changed files without replacing the built-in Code Review button
- Section Review (Git/SVN): Right-click a Git or SVN change section header and select Review Section with Codex to review the entire section in one batch
- Git and SVN Support: Automatically detects Git and SVN repositories and retrieves the appropriate diff
- New and Deleted File Support: Correctly handles untracked (new) files and deleted files
- Git History Review: Review a commit, multiple commits, or selected files in a commit from the VS Code Source Control history view
- SVN History Review: Review a revision from the SVN FILE HISTORY or REPOSITORIES view provided by the svn-scm extension
- SVN Commit Review: Review an entire SVN commit by having Codex run
svn diff -c itself
- SVN Multi-Commit Review: Add multiple commits to a review list and review them together in revision order
- Remote Changes Support: Supports reviewing incoming remote changes shown in the SVN SCM view
- Multi-Language Prompts: Supports Japanese, English, Chinese (Simplified), Korean, French, German, and Spanish
- Automatic Language Detection: Selects the review language automatically based on the VS Code UI language
- Custom Prompts: Configure your own review prompt per language
- Live Status and Cancellation: Shows running state in the tab title, status indicator, and animated progress bar without a notification; the tab's Cancel button stops the CLI process
- Review Session List: Keeps up to 20 running or completed sessions in the current VS Code window and reopens them from Code Reviewer for Codex: Show Review Sessions
- Diagnostic Logging: Records Codex invocation, process lifecycle, JSONL events, errors, and thread handling without recording prompt contents
- Diff Size Limit: Warns and handles gracefully when a directly collected diff exceeds 50KB
Usage
Every review action opens a dedicated live editor tab and runs the generated request automatically with Codex. By default, the tab shows the request, agent responses, errors, and final state. Enable detailed events to also show reasoning, command execution, file changes, MCP calls, web searches, plan updates, lifecycle events, and raw JSON.
Live updates are emitted per codex exec --json JSONL event, not per generated token. A long-running step may therefore remain unchanged until Codex emits its next event. Each review uses a separate CLI process and can run concurrently with other reviews.
Closing a live tab does not cancel its review. Use Code Reviewer for Codex: Show Review Sessions from the Command Palette to reopen any retained session. Up to 20 running or completed sessions are retained for the current VS Code window; they are not persisted across window restarts.
Review with Codex
- Install and sign in to the official Codex – OpenAI's coding agent extension (
openai.chatgpt)
- Right-click a supported SCM file, section, revision, commit, or history item
- Select the corresponding Review ... with Codex action
- Follow the review events in the live editor tab. Use the tab's Cancel button to stop the review
- After a successful run with a Codex thread ID, the completed task opens automatically in the official Codex panel
Codex reviews use the CLI bundled with the installed Codex extension. The official Codex panel is never opened while the external CLI process is running. It opens automatically only after exit code 0 and receipt of a thread ID. Opening the completed task relies on an internal Codex thread URI and may need an update when the Codex extension changes; the live result remains available if that URI fails.
The live view limits each displayed event to 256 KB and each session buffer to 5 MB. Truncation and session overflow are shown in the tab. The complete JSONL stream continues to be written with the local session ID to the Code Reviewer for Codex diagnostic output.
The extension runs Codex with the following command shape:
codex exec --json --sandbox read-only --skip-git-repo-check -C <root> -
For troubleshooting, run Code Reviewer for Codex: Show Debug Log from the Command Palette. The log records command invocation, prompt size and roots, CLI resolution and arguments, process lifecycle, complete JSONL lines, stderr, exit status, and thread URI handling. Prompt contents are not written to the debug log.
Review a Single File
- Open the SCM view (Source Control panel) in VS Code
- Right-click the file you want to review
- Select Review with Codex
- Codex reviews the file diff in a dedicated live tab

Review Multiple Files
- Select multiple files in the SCM view (
Ctrl+Click or Shift+Click)
- Right-click one of the selected files
- Select Review with Codex
- All selected diffs are sent to Codex in a single request
Review Changed Files from the GitHub Pull Request Panel
- Install the GitHub Pull Requests and Issues extension
- Open the GitHub Pull Request panel in VS Code
- In the changed-files view, click Review Changed Files with Codex
- Select one or more files from the Quick Pick
- Codex reviews the selected diffs in a single request
This action is separate from the built-in Code Review button provided by the GitHub Pull Requests extension.

Review Git Sections in Batch (Changes / Staged Changes)
- Open the SCM view (Source Control panel)
- Right-click the Changes section or Staged Changes section header
- Select Review Section with Codex
- Codex collects the selected sections with the appropriate Git commands and reviews all diffs in one batch
Review SVN Sections in Batch (Changes / Unversioned / Remote Changes)
- Open the SCM view (Source Control panel)
- Right-click the Changes, Unversioned, or Remote Changes section header of an SVN repository
- Select Review Section with Codex
- Codex collects and reviews every change in that section. Unversioned files are treated as newly added files
Review Git Commits from Source Control History
- Open the Source Control history view in VS Code
- Right-click a commit
- Select Review Commit with Codex
- Codex runs
git show for the commit and reviews the complete diff
To review only particular files in a commit, select Review File in Commit with Codex and choose one or more files from the Quick Pick.

Review Multiple Git Commits Together
- In the Source Control history view, right-click a commit and select Add Commit to Codex Review List
- Repeat for every commit you want to include. Duplicate commits are ignored
- Right-click a history item and select Review Multi Commit with Codex
- Codex runs
git show for all accumulated commits and reviews them together
- The review list is cleared after the request is successfully sent
Review SVN Revision History
- Install the svn-scm extension
- Open the FILE HISTORY or REPOSITORIES view in the SVN activity bar
- Right-click a revision entry
- Select Review with Codex
- Codex reviews the revision diff
Review a Single SVN Commit (Large Diff)
- Open the REPOSITORIES view in the SVN activity bar
- Right-click a commit row (not a file node)
- Select Review Commit with Codex
- Codex runs
svn diff -c {revision} itself and reviews the full commit diff without the 50KB direct-diff limit
Review Multiple SVN Commits Together
- Open the REPOSITORIES view in the SVN activity bar
- Right-click one or more commit rows and select Add to Codex Review List to accumulate commits. Duplicate revisions are ignored
- Once all desired commits are added, right-click any commit row
- Select Review Multi Commit with Codex
- Codex runs all
svn diff -c commands in ascending revision order and reviews the diffs together
- The review list is cleared after the request is successfully sent
Configuration
Detailed Live Events
Detailed diagnostic events are hidden by default. Enable them when command execution, reasoning, lifecycle events, or raw JSON are needed in the live tab. Changing the setting refreshes retained review tabs immediately.
{
"codex-scm-code-reviewer.showDetailedEvents": true
}
Review Language
Specify the language used for prompts sent to Codex.
{
"codex-scm-code-reviewer.reviewLanguage": "auto"
}
| Value |
Description |
auto |
Automatically selected based on the VS Code UI language (default) |
ja |
Japanese |
en |
English |
zh-cn |
Chinese (Simplified) |
ko |
Korean |
fr |
French |
de |
German |
es |
Spanish |
Custom Prompts
You can define a custom review prompt for each language.
Use {{diff}} as a placeholder for the diff content.
If {{diff}} is omitted, the diff is appended at the end of the prompt.
If left empty, the built-in template for that language is used.
{
"codex-scm-code-reviewer.reviewPrompt.en": "Review the following diff with a focus on security.\n\n{{diff}}"
}
Available setting keys:
| Setting Key |
Language |
codex-scm-code-reviewer.reviewPrompt.ja |
Japanese |
codex-scm-code-reviewer.reviewPrompt.en |
English |
codex-scm-code-reviewer.reviewPrompt.zh-cn |
Chinese (Simplified) |
codex-scm-code-reviewer.reviewPrompt.ko |
Korean |
codex-scm-code-reviewer.reviewPrompt.fr |
French |
codex-scm-code-reviewer.reviewPrompt.de |
German |
codex-scm-code-reviewer.reviewPrompt.es |
Spanish |
Requirements
- Visual Studio Code version 1.85.0 or higher
- OpenAI Codex extension (
openai.chatgpt) installed and signed in
- Codex reviews on Windows currently require the Codex Run in WSL setting to be disabled
- For SVN support, the
svn command must be available in your PATH
License
Licensed under MIT