Skip to content

pnpm install overwrites pnpm-workspace.yaml when --prefix is present #11535

@eagleoflqj

Description

@eagleoflqj

Verify latest release

  • I verified that the issue exists in the latest pnpm release

pnpm version

11.0.8

Which area(s) of pnpm are affected? (leave empty if unsure)

No response

Link to the code that reproduces this issue or a replay of the bug

https://github.com/fcitx-contrib/fcitx5-webview

Reproduction steps

fcitx5-webview already has valid pnpm-workspace.yaml.
In the parent directory of fcitx5-webview execute pnpm --prefix=fcitx5-webview install

Describe the Bug

Command fails, and the fcitx5-webview/pnpm-workspace.yaml is overwritten as

diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml
index db4260c..94e80c1 100644
--- a/pnpm-workspace.yaml
+++ b/pnpm-workspace.yaml
@@ -1,5 +1,5 @@
 allowBuilds:
-  '@parcel/watcher': true
-  '@swc/core': true
-  lmdb: true
-  msgpackr-extract: true
+  '@parcel/watcher': set this to true or false
+  '@swc/core': set this to true or false
+  lmdb: set this to true or false
+  msgpackr-extract: set this to true or false

Expected Behavior

Command succeeds, just like executing pnpm install inside fcitx5-webview directory.

Which Node.js version are you using?

24.15.0

Which operating systems have you used?

  • macOS
  • Windows
  • Linux

If your OS is a Linux based, which one it is? (Include the version if relevant)

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No fields configured for Bug.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions