Open chriscarrollsmith opened 2 months ago
I noticed some npm console output getting erroneously piped into the migration and types files. For instance, this script:
"supabase:generate-types": "npx supabase gen types typescript --local --schema public > types_db.ts"
was producing a types file that looked like this:
> scribert@0.0.1 npx > supabase gen types typescript --local --schema public export type Json = | string | number ...
To resolve this, I added the -silent flag to this command:
-silent
"supabase:generate-types": "npx --silent supabase gen types typescript --local --schema public > types_db.ts"
And instead of piping a db diff into the migration, I just used push and pull:
"supabase:push-local": "npx supabase db push --local", "supabase:pull-local": "npx supabase db pull --local", "supabase:push-remote": "npx supabase db push --remote", "supabase:pull-remote": "npx supabase db pull --remote"
I noticed some npm console output getting erroneously piped into the migration and types files. For instance, this script:
was producing a types file that looked like this:
To resolve this, I added the
-silent
flag to this command:And instead of piping a db diff into the migration, I just used push and pull: