-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
55a963f
commit 647e971
Showing
35 changed files
with
802 additions
and
284 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,4 @@ | ||
AUTH_SECRET=0cGJ5qnt9xRo2/E9cZB2TjUefAtz6B78+vItPv4DKPI= | ||
DB_HOST=oracle.netbird.cloud | ||
DB_USER=project-b | ||
DB_PASSWORD=YCNeqYguf8K6yp | ||
DB_DATABASE=project-b |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
{ | ||
"extends": "next/core-web-vitals" | ||
"extends": ["next/core-web-vitals", "prettier"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"trailingComma": "none", | ||
"semi": true, | ||
"tabWidth": 2, | ||
"singleQuote": true, | ||
"arrowParens": "avoid", | ||
"jsxSingleQuote": true, | ||
"plugins": ["prettier-plugin-tailwindcss"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,14 @@ | ||
import { env } from '@/env'; | ||
import { defineConfig } from 'drizzle-kit'; | ||
|
||
export default defineConfig({ | ||
schema: './src/schema.ts', | ||
out: './drizzle', | ||
dialect: 'mysql', | ||
dbCredentials: { | ||
host: "localhost", | ||
user: "root", | ||
database: "projectb", | ||
}, | ||
}); | ||
host: env.DB_HOST, | ||
user: env.DB_USER, | ||
database: env.DB_DATABASE, | ||
password: env.DB_PASSWORD | ||
} | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ALTER TABLE `session` MODIFY COLUMN `userId` int NOT NULL; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ALTER TABLE `session` MODIFY COLUMN `timestamp` timestamp(6) DEFAULT (now()); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,160 @@ | ||
{ | ||
"version": "5", | ||
"dialect": "mysql", | ||
"id": "bffda20b-2622-4b75-84ea-4fca92d7ef2b", | ||
"prevId": "d5d66241-ba07-4c3c-b17f-effa97d48daf", | ||
"tables": { | ||
"blogs": { | ||
"name": "blogs", | ||
"columns": { | ||
"id": { | ||
"name": "id", | ||
"type": "int", | ||
"primaryKey": false, | ||
"notNull": true, | ||
"autoincrement": true | ||
}, | ||
"title": { | ||
"name": "title", | ||
"type": "varchar(64)", | ||
"primaryKey": false, | ||
"notNull": false, | ||
"autoincrement": false | ||
}, | ||
"content": { | ||
"name": "content", | ||
"type": "text", | ||
"primaryKey": false, | ||
"notNull": false, | ||
"autoincrement": false | ||
} | ||
}, | ||
"indexes": {}, | ||
"foreignKeys": {}, | ||
"compositePrimaryKeys": { | ||
"blogs_id": { | ||
"name": "blogs_id", | ||
"columns": ["id"] | ||
} | ||
}, | ||
"uniqueConstraints": {} | ||
}, | ||
"session": { | ||
"name": "session", | ||
"columns": { | ||
"id": { | ||
"name": "id", | ||
"type": "int", | ||
"primaryKey": false, | ||
"notNull": true, | ||
"autoincrement": true | ||
}, | ||
"token": { | ||
"name": "token", | ||
"type": "varchar(64)", | ||
"primaryKey": false, | ||
"notNull": false, | ||
"autoincrement": false | ||
}, | ||
"userId": { | ||
"name": "userId", | ||
"type": "int", | ||
"primaryKey": false, | ||
"notNull": true, | ||
"autoincrement": false | ||
}, | ||
"timestamp": { | ||
"name": "timestamp", | ||
"type": "timestamp(6)", | ||
"primaryKey": false, | ||
"notNull": false, | ||
"autoincrement": false | ||
} | ||
}, | ||
"indexes": {}, | ||
"foreignKeys": { | ||
"session_userId_user_id_fk": { | ||
"name": "session_userId_user_id_fk", | ||
"tableFrom": "session", | ||
"tableTo": "user", | ||
"columnsFrom": ["userId"], | ||
"columnsTo": ["id"], | ||
"onDelete": "no action", | ||
"onUpdate": "no action" | ||
} | ||
}, | ||
"compositePrimaryKeys": { | ||
"session_id": { | ||
"name": "session_id", | ||
"columns": ["id"] | ||
} | ||
}, | ||
"uniqueConstraints": {} | ||
}, | ||
"user": { | ||
"name": "user", | ||
"columns": { | ||
"id": { | ||
"name": "id", | ||
"type": "int", | ||
"primaryKey": false, | ||
"notNull": true, | ||
"autoincrement": true | ||
}, | ||
"email": { | ||
"name": "email", | ||
"type": "varchar(320)", | ||
"primaryKey": false, | ||
"notNull": false, | ||
"autoincrement": false | ||
}, | ||
"username": { | ||
"name": "username", | ||
"type": "varchar(64)", | ||
"primaryKey": false, | ||
"notNull": false, | ||
"autoincrement": false | ||
}, | ||
"password": { | ||
"name": "password", | ||
"type": "varchar(255)", | ||
"primaryKey": false, | ||
"notNull": false, | ||
"autoincrement": false | ||
}, | ||
"verified": { | ||
"name": "verified", | ||
"type": "boolean", | ||
"primaryKey": false, | ||
"notNull": false, | ||
"autoincrement": false | ||
}, | ||
"activationToken": { | ||
"name": "activationToken", | ||
"type": "varchar(64)", | ||
"primaryKey": false, | ||
"notNull": false, | ||
"autoincrement": false | ||
} | ||
}, | ||
"indexes": {}, | ||
"foreignKeys": {}, | ||
"compositePrimaryKeys": { | ||
"user_id": { | ||
"name": "user_id", | ||
"columns": ["id"] | ||
} | ||
}, | ||
"uniqueConstraints": {} | ||
} | ||
}, | ||
"_meta": { | ||
"schemas": {}, | ||
"tables": {}, | ||
"columns": {} | ||
}, | ||
"internal": { | ||
"tables": {}, | ||
"indexes": {} | ||
} | ||
} |
Oops, something went wrong.