Skip to content

Commit 27b0d9d

Browse files
committed
fix: fix cd method
1 parent 6636b67 commit 27b0d9d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/runtime/cd.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ export function cd(dir: string) {
1111
if (dir[0] === "~") {
1212
dir = path.join(homedir() as string, dir.slice(1));
1313
} else if (dir[0] !== path.sep) {
14-
dir = new URL(dir, path.toFileUrl(cwd + path.sep)).pathname;
14+
dir = path.join(cwd, dir);
1515
}
1616
Deno.chdir(dir);
1717
} catch (err) {

0 commit comments

Comments
 (0)