Sync Toolbox
Apply published jialuohu/codex-toolbox through its existing full setup. A clear
request to update this machine authorizes this local sequence. Sync never
stages, commits, pushes, or invokes ship-toolbox; publishing is a separate task.
For health-only, skip the Git and rollout gates below and follow
health checks. A dirty checkout is allowed. Run
read-only diagnostics without updates, repairs, sign-in flows, or permission
prompts. A status-only request also remains read-only; report checkout currency
separately from component health.
For reported missing sidebar projects or sections, route read-only inspection to
$recover-codex-sidebar. A successful sync, installed skill, or available project
API does not establish restored sidebar mappings. Identify the sidebar Mac and
project host separately; health-only never authorizes a recovery or folder trust
change. Use the recovery skill's compatibility diagnostic before suggesting
manual registration, and require an explicit restore request before repairs.
Inspect first
- Resolve the checkout from
CODEX_TOOLBOX_ROOT or the user's repository
context. Verify its Git root and normalized origin identify exactly
jialuohu/codex-toolbox; do not guess another checkout or clone a replacement.
- Inspect branch, upstream, and
git status --porcelain, including untracked
files. Applying requires clean main tracking origin/main. Stop on another
branch, local changes, unpublished commits, or divergence. Never switch
branches, stash, reset, rebase, or repair history automatically.
- Record the current SHA, toolbox plugin names, versions and enabled flags from
codex plugin list --marketplace jialuo-codex-toolbox --json, and marketplace
source/root from codex plugin marketplace list --json. Keep temporary
receipts outside the checkout; do not copy credentials or full configuration.
- For a status-only request, use read-only inspection and
git ls-remote origin refs/heads/main. Do not fetch, fast-forward, refresh, install, or authenticate.
If the remote commit is unavailable locally, report the comparison limits.
Select and apply a published revision
- For an update, run
git fetch origin main, then
git rev-list --left-right --count origin/main...HEAD. The first count is
remote-only commits; the second is local-only commits. Continue only when
the second is zero. Record the full origin/main SHA as the selected revision.
- Inspect relevant GitHub Actions for that exact SHA and the applicable
workflow definitions. Wait for required runs to succeed. Failed, cancelled,
missing, or inaccessible required evidence blocks setup; do not substitute
an older green run. If no relevant workflow applies, say so and continue
without claiming CI passed.
- Recheck clean state and fast-forward with
git merge --ff-only <selected-sha>
when behind. When already current, skip the merge and still apply setup.
Require HEAD to equal the selected revision before continuing.
- Run
scripts/setup-codex-toolbox.sh --non-interactive from that committed checkout. Use the
production Git-backed marketplace on main; do not silently accept a local
development mode or a different source/ref override. The setup script owns
managed instructions, pets, default plugins, runtime dependencies, stale
configuration migrations, and third-party marketplace pins. Do not duplicate
those mechanisms or broaden them to unrelated plugins or accounts. Defer
Docmost login and permission-capable Apple Mail checks to the health report.
- Compare the installed toolbox plugins with the selected revision's plugin
manifests. Include previously installed optional plugins, not just setup
defaults. Marketplace upgrade may already refresh them; only repair remaining
mismatches, using the setup script's scoped
codex plugin remove / codex plugin add sequence. Preserve optional-plugin selection and enabled flags;
verify a supported way to restore a disabled flag before replacing that plugin.
If an optional plugin disappeared upstream, report it rather than deleting it.
Verify and report
- Require the toolbox marketplace to use Git source
https://github.com/jialuohu/codex-toolbox.git and ref main (inspect only the
relevant config fields if the CLI omits the ref). Resolve its reported root
and compare its Git SHA with the selected revision, checkout HEAD, and a
fresh remote main SHA. A concurrent advance or unavailable SHA comparison
means incomplete synchronization; do not silently claim a different revision.
- Verify every setup default and previously installed toolbox plugin against
its expected version and enabled state. Check the installed files for newly
added or changed skills, not just the marketplace listing.
- Run
scripts/sync-agents.sh --check,
python3 scripts/sync-codex-pets.py --check, third-party plugin listings for
marketplaces refreshed by setup, and codex mcp list. A successful MCP listing
proves configuration discovery, not authentication or server health.
- Follow health checks automatically after setup,
including when setup fails. Inventory all installed plugins, effective MCP
servers, and discoverable skills on this machine and in the current project.
Keep installation, runtime availability, and authentication evidence separate.
Missing evidence is unverified, never passed. Do not test real user workflows.
- In an authorized sync, attempt at most one targeted non-interactive repair per
affected Toolbox-managed component using an existing reviewed owner command.
All Git, CI, revision, runtime-lock, optional-plugin, and enabled-state gates
still apply. Re-inventory and recheck affected dependencies after a repair.
Diagnose external plugins without modifying them; health-only never repairs.
- Report the before/after SHA, CI evidence, setup result, installed version
changes, instruction/pet checks, and health coverage. Lead with a summary,
then Needs your action, then Other failures and coverage gaps. Group
shared dependency problems while retaining affected components. Each action
includes the observed problem, affected capabilities, exact next step, and
recheck instruction. Distinguish sync completion from runtime health; never
claim completion from a successful Git update or static check alone.
Interrupted setup
Stop installation at a failed setup step, collect independent read-only health
diagnostics with sync outcome failed, and report completed stages separately. Keep the
selected SHA and plugin receipt for recovery; rerun from that same committed
revision after resolving the cause. If remote main has moved, reselect and
verify its CI before a new attempt instead of mixing revisions. Never bypass
failed checks, remove live runtime locks, or terminate active services. If a
lock requires user action, identify its owner and ask the user to close it.
1---2name: sync-toolbox3description: Sync published codex-toolbox, or check installed plugins, MCP servers, and skills for health and actionable setup problems. Health-only checks do not update or repair the machine.4---56# Sync Toolbox78Apply published `jialuohu/codex-toolbox` through its existing full setup. A clear9request to update this machine authorizes this local sequence. Sync never10stages, commits, pushes, or invokes `ship-toolbox`; publishing is a separate task.1112For **health-only**, skip the Git and rollout gates below and follow13[health checks](references/health-checks.md). A dirty checkout is allowed. Run14read-only diagnostics without updates, repairs, sign-in flows, or permission15prompts. A status-only request also remains read-only; report checkout currency16separately from component health.1718For reported missing sidebar projects or sections, route read-only inspection to19`$recover-codex-sidebar`. A successful sync, installed skill, or available project20API does not establish restored sidebar mappings. Identify the sidebar Mac and21project host separately; health-only never authorizes a recovery or folder trust22change. Use the recovery skill's compatibility diagnostic before suggesting23manual registration, and require an explicit restore request before repairs.2425## Inspect first2627- Resolve the checkout from `CODEX_TOOLBOX_ROOT` or the user's repository28 context. Verify its Git root and normalized `origin` identify exactly29 `jialuohu/codex-toolbox`; do not guess another checkout or clone a replacement.30- Inspect branch, upstream, and `git status --porcelain`, including untracked31 files. Applying requires clean `main` tracking `origin/main`. Stop on another32 branch, local changes, unpublished commits, or divergence. Never switch33 branches, stash, reset, rebase, or repair history automatically.34- Record the current SHA, toolbox plugin names, versions and enabled flags from35 `codex plugin list --marketplace jialuo-codex-toolbox --json`, and marketplace36 source/root from `codex plugin marketplace list --json`. Keep temporary37 receipts outside the checkout; do not copy credentials or full configuration.38- For a status-only request, use read-only inspection and `git ls-remote origin39 refs/heads/main`. Do not fetch, fast-forward, refresh, install, or authenticate.40 If the remote commit is unavailable locally, report the comparison limits.4142## Select and apply a published revision43441. For an update, run `git fetch origin main`, then45 `git rev-list --left-right --count origin/main...HEAD`. The first count is46 remote-only commits; the second is local-only commits. Continue only when47 the second is zero. Record the full `origin/main` SHA as the selected revision.482. Inspect relevant GitHub Actions for that exact SHA and the applicable49 workflow definitions. Wait for required runs to succeed. Failed, cancelled,50 missing, or inaccessible required evidence blocks setup; do not substitute51 an older green run. If no relevant workflow applies, say so and continue52 without claiming CI passed.533. Recheck clean state and fast-forward with `git merge --ff-only <selected-sha>`54 when behind. When already current, skip the merge and still apply setup.55 Require `HEAD` to equal the selected revision before continuing.564. Run `scripts/setup-codex-toolbox.sh --non-interactive` from that committed checkout. Use the57 production Git-backed marketplace on `main`; do not silently accept a local58 development mode or a different source/ref override. The setup script owns59 managed instructions, pets, default plugins, runtime dependencies, stale60 configuration migrations, and third-party marketplace pins. Do not duplicate61 those mechanisms or broaden them to unrelated plugins or accounts. Defer62 Docmost login and permission-capable Apple Mail checks to the health report.635. Compare the installed toolbox plugins with the selected revision's plugin64 manifests. Include previously installed optional plugins, not just setup65 defaults. Marketplace upgrade may already refresh them; only repair remaining66 mismatches, using the setup script's scoped `codex plugin remove` / `codex67 plugin add` sequence. Preserve optional-plugin selection and enabled flags;68 verify a supported way to restore a disabled flag before replacing that plugin.69 If an optional plugin disappeared upstream, report it rather than deleting it.7071## Verify and report7273- Require the toolbox marketplace to use Git source74 `https://github.com/jialuohu/codex-toolbox.git` and ref `main` (inspect only the75 relevant config fields if the CLI omits the ref). Resolve its reported root76 and compare its Git SHA with the selected revision, checkout `HEAD`, and a77 fresh remote `main` SHA. A concurrent advance or unavailable SHA comparison78 means incomplete synchronization; do not silently claim a different revision.79- Verify every setup default and previously installed toolbox plugin against80 its expected version and enabled state. Check the installed files for newly81 added or changed skills, not just the marketplace listing.82- Run `scripts/sync-agents.sh --check`,83 `python3 scripts/sync-codex-pets.py --check`, third-party plugin listings for84 marketplaces refreshed by setup, and `codex mcp list`. A successful MCP listing85 proves configuration discovery, not authentication or server health.86- Follow [health checks](references/health-checks.md) automatically after setup,87 including when setup fails. Inventory all installed plugins, effective MCP88 servers, and discoverable skills on this machine and in the current project.89 Keep installation, runtime availability, and authentication evidence separate.90 Missing evidence is unverified, never passed. Do not test real user workflows.91- In an authorized sync, attempt at most one targeted non-interactive repair per92 affected Toolbox-managed component using an existing reviewed owner command.93 All Git, CI, revision, runtime-lock, optional-plugin, and enabled-state gates94 still apply. Re-inventory and recheck affected dependencies after a repair.95 Diagnose external plugins without modifying them; health-only never repairs.96- Report the before/after SHA, CI evidence, setup result, installed version97 changes, instruction/pet checks, and health coverage. Lead with a summary,98 then **Needs your action**, then **Other failures and coverage gaps**. Group99 shared dependency problems while retaining affected components. Each action100 includes the observed problem, affected capabilities, exact next step, and101 recheck instruction. Distinguish sync completion from runtime health; never102 claim completion from a successful Git update or static check alone.103104## Interrupted setup105106Stop installation at a failed setup step, collect independent read-only health107diagnostics with sync outcome `failed`, and report completed stages separately. Keep the108selected SHA and plugin receipt for recovery; rerun from that same committed109revision after resolving the cause. If remote `main` has moved, reselect and110verify its CI before a new attempt instead of mixing revisions. Never bypass111failed checks, remove live runtime locks, or terminate active services. If a112lock requires user action, identify its owner and ask the user to close it.