Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Turso not working in current version #217

Open
NoelHuibers opened this issue Nov 2, 2024 · 0 comments
Open

Turso not working in current version #217

NoelHuibers opened this issue Nov 2, 2024 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@NoelHuibers
Copy link

Config File
{
"hasSrc": true,
"packages": [
"shadcn-ui",
"drizzle",
"next-auth"
],
"preferredPackageManager": "pnpm",
"t3": false,
"alias": "~",
"analytics": true,
"rootPath": "src/",
"componentLib": "shadcn-ui",
"driver": "sqlite",
"provider": "turso",
"orm": "drizzle",
"auth": "next-auth"
}

Describe the bug
With the current Drizzle Version Turso is not a driver and instead a dialect.

To Reproduce
Steps to reproduce the behavior:

  1. Use Krimase with Turso

Expected behavior
Should just work.

Additional context
Fixed drizzle.config.ts:

import type { Config } from "drizzle-kit";
import { env } from "~/lib/env.mjs";

export default {
schema: "./src/lib/db/schema",
dialect: "turso",
out: "./src/lib/db/migrations",
dbCredentials: {
url: env.DATABASE_URL,
authToken: env.DATABASE_AUTH_TOKEN,
}
} satisfies Config;

Files needing change for the fix:

types.d.ts, src/commands/add/orm/drizzle/generatos.ts, src/commands/init/utils.ts

@NoelHuibers NoelHuibers added the bug Something isn't working label Nov 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants