chen-rn / CUA

(deprecateed) create-universal-app(CUA) is an opinionated template for creating fullstack universal apps (Expo, Next, tRPC, Prisma, Clerk, Solito, Tamagui)
https://cua-demo.vercel.app
MIT License
1.02k stars 67 forks source link

fix: Prisma scripts permission issue #4

Closed alitnk closed 1 year ago

alitnk commented 1 year ago

For some reason, when I try running yarn generate or yarn studio, I get permission denied: prisma. Adding yarn to the scripts seems to fix the issue.

This could be an issue from my side, in which case we can just close this issue.

chen-rn commented 1 year ago

Hmm! If you cd into that folder manually and run prisma generate, does it throw an error as well?

alitnk commented 1 year ago

I'd have to do:

cd packages/db
yarn prisma generate

So yarn is still used in the command.

Just running prisma generate - even in the db workspace - won't work for me.

Not sure if this has anything to do with prisma being globally installed or not.

chen-rn commented 1 year ago

Yea I think Prisma is not automatically installing their CLI if it's installed via Package manager. Adding it in would be better https://www.prisma.io/docs/reference/api-reference/command-reference

yassinebridi commented 1 year ago

@chen-rn i think you are assuming prisma is installed globaly? I had to make these changes too.

chen-rn commented 1 year ago

@chen-rn i think you are assuming prisma is installed globaly? I had to make these changes too.

True! That's my bad!