macOS-only workflow to safely update and relaunch the macOS Codex desktop app from a remote shell using the normal Sparkle updater UI. Use when the user asks to update Codex on a Mac, fix a remote Connections/app-server version mismatch, ensure Codex reopens after updating, check the installed Codex GUI/CLI/app-server version, or avoid persistent launchd reopen loops on a Mac host.
Resources
6Install
npx skillscat add neenvm/codex-remote-update Install via the SkillsCat registry.
Codex Remote Update
Overview
Use the bundled script to update Codex on the active macOS GUI host without leaving a persistent reopen loop. This skill is macOS-only because it depends on Codex.app, Sparkle, osascript, open, and the logged-in GUI session. The script checks versions, clears a skipped Sparkle version if present, opens Codex's normal Check for Updates... flow, starts a finite backup reopen watchdog, installs the update if one is ready, and verifies that both the GUI and codex app-server are running again.
Quick Start
Install as a Codex skill from GitHub:
mkdir -p "$HOME/.codex/skills"
git clone https://github.com/neenvm/codex-remote-update.git "$HOME/.codex/skills/codex-remote-update"From the skill directory:
scripts/codex-remote-update.sh --status
scripts/codex-remote-update.sh --quiet-check
scripts/codex-remote-update.sh --check-only
scripts/codex-remote-update.sh --installTo make it callable from any directory on the same Mac:
mkdir -p "$HOME/.local/bin"
ln -sf "$PWD/scripts/codex-remote-update.sh" "$HOME/.local/bin/codex-remote-update"
codex-remote-update --statusTo trigger it over SSH from another machine:
ssh <mac-host> 'zsh -lc "codex-remote-update --install"'Workflow
- Verify the target machine is the Mac that owns the Codex GUI/session. For remote-control issues, update the host shown in Connections, not the laptop viewing it.
- Run
scripts/codex-remote-update.sh --statusto capture the current GUI version, bundled CLI version, and app-server process. - Run
scripts/codex-remote-update.sh --quiet-checkto make sure no shell-visible active Codex worker processes are running. This is conservative but cannot read private Codex internal thread state. - Run
scripts/codex-remote-update.sh --check-onlywhen you want to confirm whether Sparkle has an update ready without restarting Codex. - Run
scripts/codex-remote-update.sh --installwhen a restart is acceptable. By default install refuses if the quiet check sees active Codex worker activity. Expect a brief disconnect if the current conversation is inside Codex. - After reconnecting, run
scripts/codex-remote-update.sh --statusor inspect~/Library/Logs/codex-remote-update/latest.log.
Guardrails
- Use the normal logged-in macOS app and Sparkle updater UI only.
- Do not use this skill for Linux, Windows, web-only Codex, or non-GUI hosts.
- Default install must pass the quiet check first. Use
--force-activeonly when the user explicitly accepts interrupting active Codex work. - Do not use private updater endpoints or manual app-bundle surgery.
- Do not create persistent
launchctlorKeepAlivereopen jobs. The bundled script uses a finite detached watchdog that repeatedly reopens Codex until GUI plus app-server are back, then exits. - If a previous failed update left jobs such as
codex-force-restart-*orcodex-reopen-after-*, unload them after verifying Codex is running. - Preserve user work: warn that the update will quit/relaunch Codex when running from an active Codex chat.
Script
The deterministic implementation is scripts/codex-remote-update.sh. Read or patch the script only when behavior needs to change; otherwise execute it directly.