Skip to content

Commit

Permalink
fix: Update drizzle config to be up to date with the latest version (#…
Browse files Browse the repository at this point in the history
…1881)

Co-authored-by: juliusmarminge <julius0216@outlook.com>
  • Loading branch information
gcjbr and juliusmarminge committed May 10, 2024
1 parent 12275fa commit 9e5e7d0
Show file tree
Hide file tree
Showing 8 changed files with 18 additions and 39 deletions.
5 changes: 5 additions & 0 deletions .changeset/dirty-tools-rule.md
@@ -0,0 +1,5 @@
---
"create-t3-app": patch
---

chore: update `drizzle-kit` to `0.21.0`
2 changes: 1 addition & 1 deletion cli/package.json
Expand Up @@ -77,7 +77,7 @@
"@types/fs-extra": "^11.0.4",
"@types/gradient-string": "^1.1.5",
"@types/node": "^20.11.20",
"drizzle-kit": "^0.20.14",
"drizzle-kit": "^0.21.0",
"drizzle-orm": "^0.29.4",
"mysql2": "^3.9.1",
"next": "^14.2.1",
Expand Down
2 changes: 1 addition & 1 deletion cli/src/installers/dependencyVersionMap.ts
Expand Up @@ -15,7 +15,7 @@ export const dependencyVersionMap = {

// Drizzle
"drizzle-orm": "^0.29.4",
"drizzle-kit": "^0.20.14",
"drizzle-kit": "^0.21.0",
"eslint-plugin-drizzle": "^0.2.3",
mysql2: "^3.9.1",
"@planetscale/database": "^1.16.0",
Expand Down
4 changes: 2 additions & 2 deletions cli/template/extras/config/drizzle-config-mysql.ts
Expand Up @@ -4,9 +4,9 @@ import { env } from "~/env";

export default {
schema: "./src/server/db/schema.ts",
driver: "mysql2",
dialect: "mysql",
dbCredentials: {
uri: env.DATABASE_URL,
url: env.DATABASE_URL,
},
tablesFilter: ["project1_*"],
} satisfies Config;
4 changes: 2 additions & 2 deletions cli/template/extras/config/drizzle-config-postgres.ts
Expand Up @@ -4,9 +4,9 @@ import { env } from "~/env";

export default {
schema: "./src/server/db/schema.ts",
driver: "pg",
dialect: "postgresql",
dbCredentials: {
connectionString: env.DATABASE_URL,
url: env.DATABASE_URL,
},
tablesFilter: ["project1_*"],
} satisfies Config;
2 changes: 1 addition & 1 deletion cli/template/extras/config/drizzle-config-sqlite.ts
Expand Up @@ -4,7 +4,7 @@ import { env } from "~/env";

export default {
schema: "./src/server/db/schema.ts",
driver: "libsql",
dialect: "sqlite",
dbCredentials: {
url: env.DATABASE_URL,
},
Expand Down
36 changes: 5 additions & 31 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion www/src/utils/fetchGithub.ts
Expand Up @@ -48,7 +48,7 @@ export const fetchGithub = async <T extends "commits" | "repo">(
console.warn(msg);

const response = await fetch(url);
const data = await response.json();
const data = (await response.json()) as Promise<unknown>;

const parsed = schema.safeParse(data);
if (!parsed.success) {
Expand Down

0 comments on commit 9e5e7d0

Please sign in to comment.