From be526df88ae125a0076ecf17109d16001280621c Mon Sep 17 00:00:00 2001 From: Julius Marminge Date: Tue, 24 Feb 2026 15:03:21 -0800 Subject: [PATCH] cross platform expandHomePath --- apps/server/src/main.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/server/src/main.ts b/apps/server/src/main.ts index 5e87a7a9126923f76b3632bda77feb79337909a3..4e6e840bcce4351660d6157f2d4e86d00afdc271 100644 --- a/apps/server/src/main.ts +++ b/apps/server/src/main.ts @@ -60,10 +60,10 @@ const CliEnvConfig = Config.all({ }); const expandHomePath = Effect.fn(function* (input: string) { - const { join } = yield* Path.Path; + const { join, sep } = yield* Path.Path; if (input === "~") return os.homedir(); - if (input.startsWith("~/")) { - return join(os.homedir(), input.slice(2)); + if (input.startsWith(`~${sep}`)) { + return join(os.homedir(), input.slice(sep.length)); } return input; }); -- 2.54.0