Closed tbuckley closed 1 year ago
I do not remember the motivation for omitting the scripts. Seems like an odd choice with no real benefits. Since you have a use-case for the scripts as part of the isolated output I think we should just preserve them always.
It was a quick fix so I released 1.3.2 with this change. I haven't actually tested it, but I'm pretty confident it'll work 🤞 😄
My project has a shared
database
package that uses Prisma. Prisma generates a client for interacting with your database based on your schema, and the generated files are put intonode_modules/@prisma/client
. Theprisma generate
command needs to be run on the target platform. Most guidance is to run this command using apostinstall
script within package.json (example).However, isolate-package omits out
scripts
from the generated package.json files here, so this approach currently won't work.Is it possible to add an option to preserve (specific) scripts?
For now I'm working around this with a script that appends the postinstall script to the generated package.json after running
isolate
.Thank you for creating this project!