Skip to content

feat(settings): add Codex update button (brew/npm)#364

Merged
Dimillian merged 7 commits intoDimillian:mainfrom
shaw-baobao:feat/codex-update
Feb 9, 2026
Merged

feat(settings): add Codex update button (brew/npm)#364
Dimillian merged 7 commits intoDimillian:mainfrom
shaw-baobao:feat/codex-update

Conversation

@shaw-baobao
Copy link
Contributor

This PR adds a simple "Update" action next to "Run doctor" in Settings → Codex.

What it does

  • Adds a new Tauri command codex_update that updates Codex based on detected install method:
    • Homebrew cask: brew upgrade --cask codex
    • Homebrew formula: brew upgrade codex
    • npm global: if @openai/codex is installed, runs npm install -g @openai/codex@latest
    • Otherwise returns method: "unknown" with a helpful message.
  • UI shows update result details (method, package, version before/after, output, error details).

Why

  • CodexMonitor already validates the Codex CLI via "Run doctor", but didn’t provide an in-app way to upgrade Codex. This adds a minimal, best-effort upgrade flow aligned with the official Codex installation methods.

Testing

  • npm install
  • npm test
  • cargo check (in src-tauri)

Notes

  • The update logic is best-effort and intentionally does not attempt to support every possible installation method beyond brew/npm.

@Dimillian
Copy link
Owner

@codex review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 0f0cc74532

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@shaw-baobao
Copy link
Contributor Author

Follow-up: fixed in commit 97ecd9e. App now passes the codexUpdate handler from useAppSettingsController into SettingsView (settingsProps.onRunCodexUpdate), so the Update button uses the real Tauri update path.

@Dimillian
Copy link
Owner

@codex review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 88c0c39ec9

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@shaw-baobao
Copy link
Contributor Author

Addressed the new Codex feedback in commit 3b33998: detection now treats missing brew/npm binaries as not-installed during method probing, so the flow no longer aborts early and can fall back to npm/unknown.

@Dimillian
Copy link
Owner

@codex review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3b33998f8d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@shaw-baobao
Copy link
Contributor Author

Addressed the latest Codex feedback in commit 3887895: the pre-update codex version check is now best-effort (non-fatal), so update method detection and upgrade can proceed even when the configured codex binary/path is invalid.

@Dimillian Dimillian merged commit 0882e1b into Dimillian:main Feb 9, 2026
9 checks passed
gersmann pushed a commit to gersmann/codex-monitor-web that referenced this pull request Mar 10, 2026
Co-authored-by: shaw-baobao <1175745159@qq.com>
Co-authored-by: Thomas Ricouard <ricouard77@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants