mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-08 09:51:22 +00:00
fix: Also build entry.ts into dist/entry.mjs.
This commit is contained in:
@@ -47,7 +47,7 @@ export async function resolveControlUiDistIndexPath(
|
||||
}
|
||||
const normalized = path.resolve(argv1);
|
||||
|
||||
// Case 1: entrypoint is directly inside dist/ (e.g., dist/entry.js)
|
||||
// Case 1: entrypoint is directly inside dist/ (e.g., dist/entry.mjs)
|
||||
const distDir = path.dirname(normalized);
|
||||
if (path.basename(distDir) === "dist") {
|
||||
return path.join(distDir, "control-ui", "index.html");
|
||||
|
||||
@@ -74,10 +74,8 @@ function isGatewayArgv(args: string[]): boolean {
|
||||
|
||||
const entryCandidates = [
|
||||
"dist/index.mjs",
|
||||
"dist/index.mjs",
|
||||
"dist/entry.js",
|
||||
"openclaw.mjs",
|
||||
"dist/entry.mjs",
|
||||
"openclaw.mjs",
|
||||
"scripts/run-node.mjs",
|
||||
"src/index.ts",
|
||||
];
|
||||
|
||||
@@ -37,7 +37,7 @@ describe("ports helpers", () => {
|
||||
expect(
|
||||
classifyPortListener(
|
||||
{
|
||||
commandLine: "node /Users/me/Projects/openclaw/dist/entry.js gateway",
|
||||
commandLine: "node /Users/me/Projects/openclaw/dist/entry.mjs gateway",
|
||||
},
|
||||
18789,
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user