diff --git a/src/utils/command-exists.ts b/src/utils/command-exists.ts index f609386..961b29b 100644 --- a/src/utils/command-exists.ts +++ b/src/utils/command-exists.ts @@ -73,7 +73,7 @@ const commandExistsWindowsSync = function ( ): boolean { // Regex from Julio from: https://stackoverflow.com/questions/51494579/regex-windows-path-validator if ( - !/^(?!(?:.*\s|.*\.|\W+)$)(?:[A-Za-z]:)?(?:[^\n"*:<>?|]+(?:\/\/|\/|\\\\|\\)?)+$/m.test( + !/^(?!(?:.*\s|.*\.|\W+)$)(?:[A-Za-z]:)?(?:[^\\s"*:<>?|]+(?:\/\/|\/|\\\\|\\)?)+$/m.test( commandName ) ) {