from aryan: most guides i found online weren't helpful for me, hope this helps tho :)
ssh root@<server-ip-address>Optional but recommended:
sudo apt update && sudo apt upgrade -y| version: "3.9" | |
| name: myprojectname-mysql | |
| services: | |
| # This is your local MySQL database instance | |
| mysql-db: | |
| image: mysql | |
| restart: always | |
| environment: |
| import { drizzle } from "drizzle-orm/postgres-js"; | |
| import postgres from "postgres"; | |
| import { env } from "~/env.js"; | |
| import * as schema from "./schema"; | |
| import { type PostgresJsDatabase } from "drizzle-orm/postgres-js"; | |
| // Fix for "sorry, too many clients already" | |
| declare global { |
| const createUserRequestSchema = z.object({ | |
| name: z.string(), | |
| email: z.string().email(), | |
| }) | |
| type CreateUserRequestBody = z.infer<typeof createUserRequestSchema> | |
| export default async function handler( | |
| req: NextApiRequest, | |
| res: NextApiResponse |
| // zod schema | |
| z.object({ | |
| // valid if string or: | |
| optional: z.string().optional(), // field not provided, or explicitly `undefined` | |
| nullable: z.string().nullable(), // field explicitly `null` | |
| nullish: z.string().nullish(), // field not provided, explicitly `null`, or explicitly `undefined` | |
| }); | |
| // type | |
| { |
Pre-requisite: You have to know your last commit message from your deleted branch.
git reflogSearch for message in the list:
a901eda HEAD@{18}: commit: <last commit message>
Now you have two options, either checkout revision or HEAD
Make sure everything is pushed up to your remote repository (GitHub):
git checkout mainOverwrite "main" with "better_branch":
git reset --hard better_branch| <p class="bg-gradient-to-r from-purple-400 to-green-600 bg-clip-text text-8xl font-extrabold text-transparent">Text Goes Here</p> |
| # Rename Git branch locally and remotely | |
| git branch -m old_branch new_branch # Rename branch locally | |
| git push origin :old_branch # Delete the old branch | |
| git push --set-upstream origin new_branch # Push the new branch, set local branch to track the new remote |