Closed oceandrama closed 1 year ago
@oceandrama actually I never thougt about just parsing this kind of annotation and read out the env var in the generator. 😅 But yes, this would make handling this much easier.
The thing I meant by string values in the readme is that there is a separate type in the generator config that's called EnvValue
and I thougt this type is meant to get values that are passed into the generator with the ENV("somthing")
syntax already in a transformed state. But this did not work. So it seems I choose the wrong way here.
@oceandrama I implemented even a simpler version of skipping the generator. Now only the presence of the SKIP_ZOD_PRISMA="true"
environment variable is sufficient to skip generation.
It would be a way more convinient to move
skipGenerator
setting toschema.prisma
file instead of creating the new one. Unfortunately, I don't understand the point about strings value in the README. If you are using .env file, all values inside it also parsed as strings, so why can't we use something like this?