How do I make Prisma generate new prisma.graphql? ...
# orm-help
p
How do I make Prisma generate new prisma.graphql? :s When I add new fields to User, I can't query them.
d
try
prisma deploy
p
Still returns null 😕
h
maybe bad model 🙂
l
Have you tried deleting prisma.graphql and
prisma deploy
?
p
It doesnt seem to produce a new prisma.graphql
database/datamodel.graphql avatar: String @unique src/schema.graphql avatar: String @huv1k
n
did you set up post deployment hooks to generate
prisma.graphql
?
p
@nilan uhm no. Didnt even think about. How ? 😛
the automatic
prisma.graphql
generation was removed in
1.7
and you can set up a post deployment hook to accomplish the same (or not)
p
Is it any example on how that hook would look like? Im bad at this 😕 or is it the same that is on the docs?
n
yes, at the link I shared above 🙂
p
Hmm, I still get no prisma.graphql file. I don't see any errors either.
I'm doing this on windows, idk if that makes a difference
n
what happens when you manually run the
graphql prepare
command exactly as it is written in the
hooks
?
p
warning command prepare both exists in plugin C:\Users\username\Desktop\random\dev\backend\node_modules\graphql-cli-prepare and is shipped with the graphql-cli. The plugin is being ignored.
graphql get-schema --project database got me the file I needed
but still gives that warning
n
what is the output of
graphql -v
?
it looks like you might be on an older version 🙂
p
2.16.0
n
ok that's good!
it might be related to your local
node_modules
, or it might be a bug, In any case, can you raise this issue here, so we can further look into this? https://github.com/graphql-cli/graphql-cli/issues 🙂