mirror of
https://github.com/zadam/trilium.git
synced 2025-10-20 15:19:01 +02:00
chore(dx/server): build all entrypoints with right ext
This commit is contained in:
parent
0e5108bd08
commit
dbf016adaf
@ -7,11 +7,17 @@ const outDir = join(projectDir, "dist");
|
|||||||
|
|
||||||
async function build() {
|
async function build() {
|
||||||
esbuild.build({
|
esbuild.build({
|
||||||
entryPoints: [ join(projectDir, "src/main.ts") ],
|
entryPoints: [
|
||||||
|
join(projectDir, "src/main.ts"),
|
||||||
|
join(projectDir, "src/docker_healthcheck.ts")
|
||||||
|
],
|
||||||
tsconfig: join(projectDir, "tsconfig.app.json"),
|
tsconfig: join(projectDir, "tsconfig.app.json"),
|
||||||
platform: "node",
|
platform: "node",
|
||||||
bundle: true,
|
bundle: true,
|
||||||
outdir: outDir,
|
outdir: outDir,
|
||||||
|
outExtension: {
|
||||||
|
".js": ".cjs"
|
||||||
|
},
|
||||||
format: "cjs",
|
format: "cjs",
|
||||||
external: [
|
external: [
|
||||||
"electron",
|
"electron",
|
||||||
@ -44,8 +50,7 @@ function copyAssets() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async function main() {
|
async function main() {
|
||||||
fs.rmSync(outDir, { recursive: true });
|
fs.emptyDirSync(outDir);
|
||||||
fs.mkdirSync(outDir);
|
|
||||||
await build();
|
await build();
|
||||||
copyAssets();
|
copyAssets();
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user