Skip to content

Commit 0ba4513

Browse files
authored
Fix tsup on windows
1 parent 42926d0 commit 0ba4513

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/commands/runify.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import globby from "globby";
22
import pLimit from "p-limit";
33
import fs from "fs-extra";
44
import { DepGraph } from "dependency-graph";
5-
import { resolve, join, dirname } from "path";
5+
import { resolve, join, dirname, sep, normalize } from "path";
66
import { Consola } from "consola";
77
import ncc from "@vercel/ncc";
88
import { build as tsup } from "tsup";
@@ -109,7 +109,7 @@ async function runify(
109109
_config: BobConfig,
110110
reporter: Consola
111111
) {
112-
const cwd = packagePath.replace("/package.json", "");
112+
const cwd = packagePath.replace(`${sep}package.json`, '');
113113
const pkg = await readPackageJson(cwd);
114114
const buildOptions: BuildOptions = pkg.buildOptions || {};
115115

@@ -235,7 +235,7 @@ async function compile(
235235
const out = join(cwd, "dist");
236236

237237
await tsup({
238-
entryPoints: [join(cwd, entryPoint)],
238+
entryPoints: [normalize(join(cwd, entryPoint))],
239239
outDir: out,
240240
target: "node16",
241241
format: ["cjs"],

0 commit comments

Comments
 (0)