Closed hiyokotaisa closed 1 year ago
Fixes #442
win_zip
From .NET 4.6.1, Windows is able to swich path separater from backslash to forwardslash. https://learn.microsoft.com/en-us/dotnet/framework/migration-guide/mitigation-ziparchiveentry-fullname-path-separator
So I added [System.AppContext]::SetSwitch('Switch.System.IO.Compression.ZipFile.UseBackslash', $false) to use forwardslash forcibly to avoid warning when extracting in non-windows environment.
[System.AppContext]::SetSwitch('Switch.System.IO.Compression.ZipFile.UseBackslash', $false)
SUMMARY
Fixes #442
ISSUE TYPE
COMPONENT NAME
win_zip
ADDITIONAL INFORMATION
From .NET 4.6.1, Windows is able to swich path separater from backslash to forwardslash. https://learn.microsoft.com/en-us/dotnet/framework/migration-guide/mitigation-ziparchiveentry-fullname-path-separator
So I added
[System.AppContext]::SetSwitch('Switch.System.IO.Compression.ZipFile.UseBackslash', $false)
to use forwardslash forcibly to avoid warning when extracting in non-windows environment.