Skip to content

Commit

Permalink
Always format from Win32 to Posix
Browse files Browse the repository at this point in the history
  • Loading branch information
Cristiano Belloni committed Jul 5, 2022
1 parent 799b789 commit e3809a8
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ import path from 'path';

export function normalizeToPosix<T extends string | undefined>(pathName: T): T {
return (
pathName ? pathName.split(path.sep).join(path.posix.sep) : pathName
pathName ? pathName.split(path.win32.sep).join(path.posix.sep) : pathName
) as T;
}

0 comments on commit e3809a8

Please sign in to comment.