From 8d2fa232c0bf0b3d58f0cf48a1e90f621fa42503 Mon Sep 17 00:00:00 2001 From: Jacob Clarke Date: Sun, 15 May 2022 01:53:08 +1000 Subject: [PATCH] Should fix absolute path issue on windows --- src/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/index.ts b/src/index.ts index 7014b59..f90fa8b 100644 --- a/src/index.ts +++ b/src/index.ts @@ -20,7 +20,7 @@ const askForFilePath = async () => const ensureFilePath = async () => { let answer = await askForFilePath() while (!answer) answer = await askForFilePath() - const isAbsolutePath = answer.match(/^\//) + const isAbsolutePath = answer.match(/^(\/)|(\w{1}\:)/) if (!isAbsolutePath) answer = runtimeDir + answer return answer }