fix(install): use npm prefix directly on Windows, not prefix/bin#80
Open
arosstale wants to merge 1 commit intoopenclaw:mainfrom
Open
fix(install): use npm prefix directly on Windows, not prefix/bin#80arosstale wants to merge 1 commit intoopenclaw:mainfrom
arosstale wants to merge 1 commit intoopenclaw:mainfrom
Conversation
On Windows, npm global binaries live in the prefix directory itself (e.g. C:\Users\User\AppData\Roaming\npm\openclaw.cmd), not in a bin/ subfolder. The bin/ convention is Unix-only. The installer was adding ...\npm\bin to PATH, but the executable was at ...\npm — so openclaw was never found on PATH after install. Fixes openclaw/openclaw#19921
|
@arosstale is attempting to deploy a commit to the Jamie's projects Team on Vercel. A member of the Team first needs to authorize it. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
On Windows,
npm config get prefixreturns e.g.C:\Users\User\AppData\Roaming\npmand binaries likeopenclaw.cmdlive directly in that folder.The installer was appending
\bin(a Unix convention), so it added...\npm\binto PATH — but the executable was at...\npm. Result:openclawnot found after install.Fix
Use
$npmPrefixdirectly instead ofJoin-Path $npmPrefix "bin". Also fix the "Expected path" hint message.Diff
3 lines changed in
public/install.ps1.Testing
Confirmed on Windows 11 with Node 22 + npm 10:
npm config get prefix→C:\Users\Artale\AppData\Roaming\npmopenclaw.cmdlives atC:\Users\Artale\AppData\Roaming\npm\openclaw.cmd(nobin/subfolder)Fixes openclaw/openclaw#19921