Skip to content

🤖 fix: start the shown skills CLI command in the home folder - #7168

Merged
ThomasK33 merged 2 commits into
mainfrom
plugin-installs/skills-cli-cwd
Oct 22, 2026
Merged

ThomasK33 merged 2 commits into
mainfrom
plugin-installs/skills-cli-cwd

Conversation

@ThomasK33

@ThomasK33 ThomasK33 commented Oct 22, 2026 •

Copy link
Copy Markdown
Member

Summary

The Skills CLI command that Settings → Plugins shows for you to copy starts with cd ~ && on macOS and Linux, so npx starts in your home folder. On Windows the command has no prefix, because no single form works in cmd.exe, PowerShell and Git Bash, and Settings tells you to run it from your home folder. npx prefers a matching skills package in the current folder's node_modules over the registry. So the copied command, run inside a checkout that someone else controls, could start a planted copy of the CLI.

Background

Codex security review raised this on #7132 (P1). The maintainer decided it does not block the stack and asked for this follow-up. Refs #7123 (item 35).

Implementation

  • skillsCliCommand adds the fixed POSIX prefix, never built from input. It adds no prefix on Windows. The existing check that every argument is safe to show unquoted is unchanged.
  • The line above the command in Settings and the paragraph in docs/agents/agent-skills.mdx say why the command starts in the home folder.

Validation

A new test runs the shown command in a real /bin/sh. It starts from a folder with a planted node_modules/skills and uses a stand-in npx that prints its working folder. The test fails without the prefix and passes with it.

Risks

Low. Only the shown text changes. Xum runs nothing.


Generated with xum • Model: anthropic:claude-opus-5-5 • Thinking: high • Cost: $114.77

npx prefers a matching skills package in the working folder's node_modules
over the registry, so the copied command run inside an attacker's checkout
would start the planted copy. The command now changes to the home folder
first (cmd.exe: cd /d "%USERPROFILE%"). Refs #7123 (item 35).
@mintlify

mintlify Bot commented Oct 22, 2026 •

Copy link
Copy Markdown

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated
Mux 🟢 Ready View Preview Oct 22, 2026, 4:06 PM

💡 Tip: Enable Automations to automatically generate PRs for you.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 22, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-22T16:06:56.522402Z b1a1e8c New commits
🔒 Security Review ✅ Completed 2026-10-22T16:08:20.795038Z b1a1e8c New commits
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

github-actions Bot commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

🟢 e2e stories (Haiku): 8 passed

21 agent steps · 7 replayed from cache · 25 model calls · 210.9k tokens (76% cached)
Spend: $0.01 of the $1.00 cap (proxy ledger)

All 8 tests in 8 files
Test Agent Time
🟢 chatRestart.e2e.ts · 1 passed 2 steps · 4 calls 24.2s
🟢 a chat survives a restart of the server 2 steps · 4 calls 24.2s
🟢 compaction.e2e.ts · 1 passed 3 steps · 7 calls 46.5s
🟢 /compact replaces the old chat with a summary 3 steps · 7 calls 46.5s
🟢 pluginTrustRestart.e2e.ts · 1 passed 4 steps · 2 calls 11.2s
🟢 a trusted plugin hook stays trusted after the server restarts 4 steps · 2 calls 11.2s
🟢 settingsRoundTrip.e2e.ts · 1 passed 3 steps · 4 calls 29.1s
🟢 a chat survives trips through Settings 3 steps · 4 calls 29.1s
🟢 sidebarPerWorkspace.e2e.ts · 1 passed 4 steps · 1 call 4.8s
🟢 a new workspace starts with its right sidebar collapsed while another keeps it open 4 steps · 1 call 4.8s
🟢 smoke.e2e.ts · 1 passed 2 steps · 1 call 2.4s
🟢 the agent opens the playground workspace 2 steps · 1 call 2.4s
🟢 streamErrors.e2e.ts · 1 passed 1 step · 1 call 8.6s
🟢 stream errors show in the chat, and the chat recovers 1 step · 1 call 8.6s
🟢 todoNudge.e2e.ts · 1 passed 2 steps · 5 calls 25.1s
🟢 the agent finishes open TODO items after the turn-end nudge 2 steps · 5 calls 25.1s

e2e 0.20.0 · 2m 36s · web · run artifacts

🟢 e2e Electron stories (Haiku): 3 passed

3 agent steps · 3 model calls · 8.1k tokens (32% cached)
Spend: $0.00 of the $1.00 cap (proxy ledger)

All 3 tests in 3 files
Test Agent Time
🟢 electron/deepLink.e2e.ts · 1 passed 1 step · 1 call 6.6s
🟢 a deep link of a second launch starts a chat in the running app 1 step · 1 call 6.6s
🟢 electron/menuBar.e2e.ts · 1 passed 1 step · 1 call 6.7s
🟢 the workspace menu bar is the desktop title bar 1 step · 1 call 6.7s
🟢 electron/smoke.e2e.ts · 1 passed 1 step · 1 call 5.8s
🟢 Xum Electron opens the playground workspace 1 step · 1 call 5.8s

e2e 0.20.0 · 21.8s · electron · run artifacts

🟢 e2e agent repros (Haiku): no tests selected

Spend: $0.00 of the $1.00 cap (proxy ledger)

e2e 0.20.0 · 6.3s · 2 targets (web, phone) · run artifacts

@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

The Code Review lane for this head has shown Running for several hours with no result.

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

Copy link
Copy Markdown

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: c783f720c7

ℹ️ 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".

Comment thread src/node/services/agentPlugins/skillsCli.ts Outdated
@chatgpt-codex-connector

Copy link
Copy Markdown

🛡️ Codex Security Review · Automatically triggered

Security review completed. No security issues were found in this pull request.

Reviewed commit: c783f720c7

View security finding report

Only the user who started this review can view the report in Codex.

ℹ️ About Codex security reviews in GitHub

This is an experimental Codex feature. Security reviews are triggered when:

  • You comment "@codex security review"
  • A regular code review gets triggered (for example, "@codex review" or when a PR is opened), and you’re opted in so security review runs alongside code review

Once complete, Codex will leave suggestions, or a comment if no findings are found.

Xum's Windows terminal prefers Git Bash or PowerShell, where cd /d and
%USERPROFILE% (and && in Windows PowerShell) do not work. No single prefix works
in every Windows shell, so the Windows command has none and Settings asks the
user to run it from the home folder. macOS and Linux keep cd ~ &&.
@ThomasK33
ThomasK33 added this pull request to the merge queue Oct 22, 2026
Merged via the queue into main with commit ec9674c Oct 22, 2026
36 of 37 checks passed
@ThomasK33
ThomasK33 deleted the plugin-installs/skills-cli-cwd branch October 22, 2026 17:02

This branch was successfully deployed

1 active deployment
staging - docs — b1a1e8ce Deployed Oct 22, 2026 by mintlify[bot]
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.

1 participant