Browse Source

build(opencode): shrink single-file executable size (#22362)

Luke Parker 6 months ago
parent
commit
9b2648dd57
1 changed files with 3 additions and 0 deletions
  1. 3 0
      packages/opencode/script/build.ts

+ 3 - 0
packages/opencode/script/build.ts

@@ -197,6 +197,9 @@ for (const item of targets) {
     tsconfig: "./tsconfig.json",
     tsconfig: "./tsconfig.json",
     plugins: [plugin],
     plugins: [plugin],
     external: ["node-gyp"],
     external: ["node-gyp"],
+    format: "esm",
+    minify: true,
+    splitting: true,
     compile: {
     compile: {
       autoloadBunfig: false,
       autoloadBunfig: false,
       autoloadDotenv: false,
       autoloadDotenv: false,