Skip to content

Commit f98bf5e

Browse files
committed
Output relative to __dirname
1 parent 3db32b5 commit f98bf5e

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

build.mjs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,11 @@ const onEndPlugin = {
6464

6565
const context = await esbuild.context({
6666
// Include upload-lib.ts as an entry point for use in testing environments.
67-
entryPoints: globSync([`${SRC_DIR}/*-action.ts`, `${SRC_DIR}/*-action-post.ts`, "src/upload-lib.ts"]),
67+
entryPoints: globSync([
68+
`${SRC_DIR}/*-action.ts`,
69+
`${SRC_DIR}/*-action-post.ts`,
70+
"src/upload-lib.ts",
71+
]),
6872
bundle: true,
6973
format: "cjs",
7074
outdir: OUT_DIR,
@@ -78,6 +82,6 @@ const context = await esbuild.context({
7882
});
7983

8084
const result = await context.rebuild();
81-
await writeFile("meta.json", JSON.stringify(result.metafile));
85+
await writeFile(join(__dirname, "meta.json"), JSON.stringify(result.metafile));
8286

8387
await context.dispose();

0 commit comments

Comments
 (0)