From 8c5add9390ae450e1d7634db2be935dce4480563 Mon Sep 17 00:00:00 2001 From: XP Date: Thu, 26 Feb 2026 16:43:50 -0800 Subject: [PATCH] Always use posix path separators --- src/index.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/index.ts b/src/index.ts index f655706..f724798 100755 --- a/src/index.ts +++ b/src/index.ts @@ -143,7 +143,10 @@ function setProjectReferences(options: SetProjectReferencesOptions): void { // create reference only to modules with tsconfig file .filter((linkedModule): linkedModule is Module => !!nullOnNotfound(() => getTsConfigJson(linkedModule.path))) - .map(linkedModule => path.relative(module.path, linkedModule.path)) + .map(linkedModule => { + // parse path using native path separators, but always format the output as posix + return path.relative(module.path, linkedModule.path).split(path.sep).join(path.posix.sep) + }) if (isEqual(sortBy(currentReferences), sortBy(desiredReferences)) === false) { everythingIsFine = false