pnpm doesn't add binary to node_modules/.bin
if bin command is prefixed (@prefix/package-name)
#7112
Closed
2 of 4 tasks
Labels
Verify latest release
pnpm version
8.6.0
Which area(s) of pnpm are affected? (leave empty if unsure)
CLI
Link to the code that reproduces this issue or a replay of the bug
https://github.com/marvinjude/prefixed-package-bin-issue
Reproduction steps
Describe the Bug
If a package
@prefix/package-name
ships with abin
field like so:After an install, one would expect that pnpm would add the binary
package-name
tonode_modules/.bin
(just like in npm, bun and yarn v2) but that doesn't happen. Doing apnpm patch
on such a package and changing the command to "package-name" without the prefix gets it to work. Another typical fix for this on the package author's end would be to change the above bin configuration toExpected Behavior
pnpm should add binary to
node_modules/.bin
for packages with prefixed commands like the below:so that you can run
pnpm exec package-name
.Happy to work on this with some directions if the team considers this a bug
Which Node.js version are you using?
18.17.1
Which operating systems have you used?
If your OS is a Linux based, which one it is? (Include the version if relevant)
No response
The text was updated successfully, but these errors were encountered: