fix(docs): align prisma init config examples#7917
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (16)
WalkthroughSixteen documentation files across Prisma's ORM database guides are synchronized with the current Prisma CLI initialization output. All ChangesPrisma Config Documentation Examples
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~4 minutes Possibly related issues
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ESLint
ESLint skipped: no ESLint configuration detected in root package.json. To enable, add Comment |
Summary
prisma.config.tssnippets to match currentprisma initoutputdefineConfig, envexamples withdefineConfigplusprocess.env["DATABASE_URL"]dotenvstep because currentprisma initalready generates itRoot cause
The docs showed an older generated
prisma.config.tsshape, while Prisma 7.8.0 now generates comments, imports onlydefineConfig, and readsDATABASE_URLfromprocess.env.Validation
npx --yes prisma@latest init --datasource-provider postgresql --output ../generated/prismanpx --yes prisma@latest init --datasource-provider mongodb --output ../generated/prismanpx --yes prisma@latest init --datasource-provider sqlite --output ../generated/prismarg -n 'defineConfig, env|url: env\\("DATABASE_URL"\\)|engine: "classic"|Adddotenvtoprisma.config.ts' apps/docs/content/docs/\\(index\\)/prisma-orm -g '*.mdx' -S\n-cd apps/docs && pnpm exec cspell $(git -C ../.. diff --name-only HEAD~1 -- apps/docs/content/docs/\\(index\\)/prisma-orm/\'*.mdx\' | sed 's#^apps/docs/##') --show-context\n-git diff --check\n\nFixesprisma init ...command generates different output, than what is shown in the docs #7818\nSummary by CodeRabbit