Closed
Description
Is there an existing issue for this?
- I have searched the existing issues
This issue exists in the latest npm version
- I am using the latest npm
Current Behavior
With [email protected]
:
❯ npm pkg get
{
"name": "prepack-error",
"version": "1.0.0",
"main": "index.js",
"scripts": {
"prepack": "npm run build -w workspace"
},
"workspaces": [
"workspace"
]
}
❯ npm pkg get -w workspace
{
"workspace": {
"name": "workspace",
"version": "1.0.0",
"main": "index.js",
"scripts": {
"build": "exit 1"
}
}
}
❯ npm pack
npm ERR! code 1
npm ERR! path /Users/lukekarrys/Desktop/garbage/prepack-error
npm ERR! er.stdout.trim is not a function
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/lukekarrys/.npm/_logs/2022-10-27T19_42_22_339Z-debug-0.log
Expected Behavior
It should show the message from npm run build -w workspace
instead of an internal npm error.