chore(migrations): remove migrations

This commit is contained in:
Mauricio Siu
2024-10-03 23:47:34 -06:00
parent 388ded9aa5
commit 3ce25e2ac8
6 changed files with 309 additions and 4163 deletions

View File

@@ -1 +0,0 @@
ALTER TABLE "ssh-key" ADD COLUMN "privateKey" text DEFAULT '' NOT NULL;

View File

@@ -1,6 +0,0 @@
ALTER TABLE "ssh-key" ADD COLUMN "adminId" text;--> statement-breakpoint
DO $$ BEGIN
ALTER TABLE "ssh-key" ADD CONSTRAINT "ssh-key_adminId_admin_adminId_fk" FOREIGN KEY ("adminId") REFERENCES "public"."admin"("adminId") ON DELETE cascade ON UPDATE no action;
EXCEPTION
WHEN duplicate_object THEN null;
END $$;

File diff suppressed because it is too large Load Diff

View File

@@ -1,24 +1,28 @@
import { build } from "esbuild"; // import { build } from "esbuild";
import path from "node:path"; // import alias from "esbuild-plugin-alias";
// import path from "node:path";
// import { fileURLToPath } from "node:url";
// const __filename = fileURLToPath(import.meta.url); // get the resolved path to the file
// const __dirname = path.dirname(__filename);
build({ // build({
entryPoints: ["./src/**/*.ts", "./src/**/*.tsx"], // Punto de entrada principal de tu aplicación // entryPoints: ["./src/**/*.ts"],
outdir: "dist", // // outfile: "./dist/index.js",
platform: "node", // outdir: "./dist",
format: "esm", // bundle: true,
sourcemap: false, // minify: false,
tsconfig: "./tsconfig.server.json", // platform: "node",
plugins: [ // target: "esnext",
// TsconfigPathsPlugin({ tsconfig: "./tsconfig.server.json" }), // format: "esm",
{ // plugins: [
name: "AddJsExtensions", // alias({
setup(build) { // "@/server": path.resolve(__dirname, "src"),
build.onResolve({ filter: /.*/ }, (args) => { // }),
if (args.path.startsWith(".") && !path.extname(args.path)) { // ],
return { path: `${args.path}.js` }; // packages: "external",
} // // Opcional: si deseas emitir declaraciones de tipos con esbuild-plugin-dts
}); // })
}, // .then(() => {
}, // console.log("Build successful");
], // })
}).catch(() => process.exit(1)); // .catch(() => process.exit(1));

View File

@@ -5,10 +5,10 @@
"types": "dist/index.d.ts", "types": "dist/index.d.ts",
"type": "module", "type": "module",
"scripts": { "scripts": {
"dev": "rm -rf ./dist && tsc --project tsconfig.server.json && tsc-alias -p tsconfig.server.json --watch",
"build": "rm -rf ./dist && tsc --project tsconfig.server.json && tsc-alias -p tsconfig.server.json", "build": "rm -rf ./dist && tsc --project tsconfig.server.json && tsc-alias -p tsconfig.server.json",
"esbuild": "tsx --watch ./esbuild.config.ts & tsc-alias -p tsconfig.server.json --watch", "build:types": "tsc --emitDeclarationOnly --experimenta-dts",
"build:types": "tsc --emitDeclarationOnly --experimenta-dts" "dev": "rm -rf ./dist && pnpm esbuild && tsc --emitDeclarationOnly --outDir dist -p tsconfig.server.json",
"esbuild": "tsx ./esbuild.config.ts"
}, },
"dependencies": { "dependencies": {
"rotating-file-stream": "3.2.3", "rotating-file-stream": "3.2.3",
@@ -67,7 +67,6 @@
"esbuild": "0.20.2", "esbuild": "0.20.2",
"postcss": "^8.4.31", "postcss": "^8.4.31",
"typescript": "^5.4.2", "typescript": "^5.4.2",
"@types/ssh2": "1.15.1", "@types/ssh2": "1.15.1"
"tsup": "6.4.0"
} }
} }