diff --git a/Misc/Cursors.zip b/Misc/Cursors.zip new file mode 100644 index 00000000..56d78ab9 Binary files /dev/null and b/Misc/Cursors.zip differ diff --git a/AppX/Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx b/Misc/Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx similarity index 100% rename from AppX/Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx rename to Misc/Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx diff --git a/src/Sophia_Script_for_Windows_10/Module/Sophia.psm1 b/src/Sophia_Script_for_Windows_10/Module/Sophia.psm1 index 4e415e96..fa941ab1 100644 --- a/src/Sophia_Script_for_Windows_10/Module/Sophia.psm1 +++ b/src/Sophia_Script_for_Windows_10/Module/Sophia.psm1 @@ -3985,13 +3985,12 @@ function Cursors New-Item -Path "$env:SystemRoot\Cursors\W11_dark_v2.2" -ItemType Directory -Force } - $Parameters = @{ - Path = "$DownloadsFolder\Cursors.zip" - DestinationPath = "$env:SystemRoot\Cursors\W11_dark_v2.2" - Force = $true - Verbose = $true + Add-Type -Assembly System.IO.Compression.FileSystem + $ZIP = [IO.Compression.ZipFile]::OpenRead("$DownloadsFolder\Cursors.zip") + $ZIP.Entries | Where-Object -FilterScript {$_.FullName -like "dark/*.*"} | ForEach-Object -Process { + [IO.Compression.ZipFileExtensions]::ExtractToFile($_, "$env:SystemRoot\Cursors\W11_dark_v2.2\$($_.Name)", $true) } - Expand-Archive @Parameters + $ZIP.Dispose() Remove-Item -Path "$DownloadsFolder\Cursors.zip" -Force @@ -4103,13 +4102,12 @@ function Cursors New-Item -Path "$env:SystemRoot\Cursors\W11_light_v2.2" -ItemType Directory -Force } - $Parameters = @{ - Path = "$DownloadsFolder\Cursors.zip" - DestinationPath = "$env:SystemRoot\Cursors\W11_light_v2.2" - Force = $true - Verbose = $true + Add-Type -Assembly System.IO.Compression.FileSystem + $ZIP = [IO.Compression.ZipFile]::OpenRead("$DownloadsFolder\Cursors.zip") + $ZIP.Entries | Where-Object -FilterScript {$_.FullName -like "light/*.*"} | ForEach-Object -Process { + [IO.Compression.ZipFileExtensions]::ExtractToFile($_, "$env:SystemRoot\Cursors\W11_light_v2.2\$($_.Name)", $true) } - Expand-Archive @Parameters + $ZIP.Dispose() Remove-Item -Path "$DownloadsFolder\Cursors.zip" -Force @@ -10763,10 +10761,10 @@ function HEIF return } - # https://github.com/farag2/Sophia-Script-for-Windows/tree/master/AppX + # https://github.com/farag2/Sophia-Script-for-Windows/tree/master/Misc $DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}" $Parameters = @{ - Uri = "https://github.com/farag2/Sophia-Script-for-Windows/raw/master/AppX/Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx" + Uri = "https://github.com/farag2/Sophia-Script-for-Windows/raw/master/Misc/Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx" OutFile = "$DownloadsFolder\Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx" UseBasicParsing = $true Verbose = $true diff --git a/src/Sophia_Script_for_Windows_10_LTSC_2019/Module/Sophia.psm1 b/src/Sophia_Script_for_Windows_10_LTSC_2019/Module/Sophia.psm1 index 50241691..c6b96079 100644 --- a/src/Sophia_Script_for_Windows_10_LTSC_2019/Module/Sophia.psm1 +++ b/src/Sophia_Script_for_Windows_10_LTSC_2019/Module/Sophia.psm1 @@ -2959,13 +2959,12 @@ function Cursors New-Item -Path "$env:SystemRoot\Cursors\W11_dark_v2.2" -ItemType Directory -Force } - $Parameters = @{ - Path = "$DownloadsFolder\Cursors.zip" - DestinationPath = "$env:SystemRoot\Cursors\W11_dark_v2.2" - Force = $true - Verbose = $true + Add-Type -Assembly System.IO.Compression.FileSystem + $ZIP = [IO.Compression.ZipFile]::OpenRead("$DownloadsFolder\Cursors.zip") + $ZIP.Entries | Where-Object -FilterScript {$_.FullName -like "dark/*.*"} | ForEach-Object -Process { + [IO.Compression.ZipFileExtensions]::ExtractToFile($_, "$env:SystemRoot\Cursors\W11_dark_v2.2\$($_.Name)", $true) } - Expand-Archive @Parameters + $ZIP.Dispose() Remove-Item -Path "$DownloadsFolder\Cursors.zip" -Force @@ -3077,13 +3076,12 @@ function Cursors New-Item -Path "$env:SystemRoot\Cursors\W11_light_v2.2" -ItemType Directory -Force } - $Parameters = @{ - Path = "$DownloadsFolder\Cursors.zip" - DestinationPath = "$env:SystemRoot\Cursors\W11_light_v2.2" - Force = $true - Verbose = $true + Add-Type -Assembly System.IO.Compression.FileSystem + $ZIP = [IO.Compression.ZipFile]::OpenRead("$DownloadsFolder\Cursors.zip") + $ZIP.Entries | Where-Object -FilterScript {$_.FullName -like "light/*.*"} | ForEach-Object -Process { + [IO.Compression.ZipFileExtensions]::ExtractToFile($_, "$env:SystemRoot\Cursors\W11_light_v2.2\$($_.Name)", $true) } - Expand-Archive @Parameters + $ZIP.Dispose() Remove-Item -Path "$DownloadsFolder\Cursors.zip" -Force diff --git a/src/Sophia_Script_for_Windows_10_LTSC_2021/Module/Sophia.psm1 b/src/Sophia_Script_for_Windows_10_LTSC_2021/Module/Sophia.psm1 index 8f561a1c..1ee8acfa 100644 --- a/src/Sophia_Script_for_Windows_10_LTSC_2021/Module/Sophia.psm1 +++ b/src/Sophia_Script_for_Windows_10_LTSC_2021/Module/Sophia.psm1 @@ -3330,13 +3330,12 @@ function Cursors New-Item -Path "$env:SystemRoot\Cursors\W11_dark_v2.2" -ItemType Directory -Force } - $Parameters = @{ - Path = "$DownloadsFolder\Cursors.zip" - DestinationPath = "$env:SystemRoot\Cursors\W11_dark_v2.2" - Force = $true - Verbose = $true + Add-Type -Assembly System.IO.Compression.FileSystem + $ZIP = [IO.Compression.ZipFile]::OpenRead("$DownloadsFolder\Cursors.zip") + $ZIP.Entries | Where-Object -FilterScript {$_.FullName -like "dark/*.*"} | ForEach-Object -Process { + [IO.Compression.ZipFileExtensions]::ExtractToFile($_, "$env:SystemRoot\Cursors\W11_dark_v2.2\$($_.Name)", $true) } - Expand-Archive @Parameters + $ZIP.Dispose() Remove-Item -Path "$DownloadsFolder\Cursors.zip" -Force @@ -3448,13 +3447,12 @@ function Cursors New-Item -Path "$env:SystemRoot\Cursors\W11_light_v2.2" -ItemType Directory -Force } - $Parameters = @{ - Path = "$DownloadsFolder\Cursors.zip" - DestinationPath = "$env:SystemRoot\Cursors\W11_light_v2.2" - Force = $true - Verbose = $true + Add-Type -Assembly System.IO.Compression.FileSystem + $ZIP = [IO.Compression.ZipFile]::OpenRead("$DownloadsFolder\Cursors.zip") + $ZIP.Entries | Where-Object -FilterScript {$_.FullName -like "light/*.*"} | ForEach-Object -Process { + [IO.Compression.ZipFileExtensions]::ExtractToFile($_, "$env:SystemRoot\Cursors\W11_light_v2.2\$($_.Name)", $true) } - Expand-Archive @Parameters + $ZIP.Dispose() Remove-Item -Path "$DownloadsFolder\Cursors.zip" -Force diff --git a/src/Sophia_Script_for_Windows_10_PowerShell_7/Module/Sophia.psm1 b/src/Sophia_Script_for_Windows_10_PowerShell_7/Module/Sophia.psm1 index 677b276e..12386252 100644 --- a/src/Sophia_Script_for_Windows_10_PowerShell_7/Module/Sophia.psm1 +++ b/src/Sophia_Script_for_Windows_10_PowerShell_7/Module/Sophia.psm1 @@ -3987,13 +3987,12 @@ function Cursors New-Item -Path "$env:SystemRoot\Cursors\W11_dark_v2.2" -ItemType Directory -Force } - $Parameters = @{ - Path = "$DownloadsFolder\Cursors.zip" - DestinationPath = "$env:SystemRoot\Cursors\W11_dark_v2.2" - Force = $true - Verbose = $true + Add-Type -Assembly System.IO.Compression.FileSystem + $ZIP = [IO.Compression.ZipFile]::OpenRead("$DownloadsFolder\Cursors.zip") + $ZIP.Entries | Where-Object -FilterScript {$_.FullName -like "dark/*.*"} | ForEach-Object -Process { + [IO.Compression.ZipFileExtensions]::ExtractToFile($_, "$env:SystemRoot\Cursors\W11_dark_v2.2\$($_.Name)", $true) } - Expand-Archive @Parameters + $ZIP.Dispose() Remove-Item -Path "$DownloadsFolder\Cursors.zip" -Force @@ -4105,13 +4104,13 @@ function Cursors New-Item -Path "$env:SystemRoot\Cursors\W11_light_v2.2" -ItemType Directory -Force } - $Parameters = @{ - Path = "$DownloadsFolder\Cursors.zip" - DestinationPath = "$env:SystemRoot\Cursors\W11_light_v2.2" - Force = $true - Verbose = $true + Add-Type -Assembly System.IO.Compression.FileSystem + $ZIP = [IO.Compression.ZipFile]::OpenRead("$DownloadsFolder\Cursors.zip") + $ZIP.Entries | Where-Object -FilterScript {$_.FullName -like "light/*.*"} | ForEach-Object -Process { + [IO.Compression.ZipFileExtensions]::ExtractToFile($_, "$env:SystemRoot\Cursors\W11_light_v2.2\$($_.Name)", $true) } - Expand-Archive @Parameters + $ZIP.Dispose() + Remove-Item -Path "$DownloadsFolder\Cursors.zip" -Force @@ -10801,10 +10800,10 @@ function HEIF return } - # https://github.com/farag2/Sophia-Script-for-Windows/tree/master/AppX + # https://github.com/farag2/Sophia-Script-for-Windows/tree/master/Misc $DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}" $Parameters = @{ - Uri = "https://github.com/farag2/Sophia-Script-for-Windows/raw/master/AppX/Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx" + Uri = "https://github.com/farag2/Sophia-Script-for-Windows/raw/master/Misc/Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx" OutFile = "$DownloadsFolder\Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx" UseBasicParsing = $true Verbose = $true diff --git a/src/Sophia_Script_for_Windows_11/Module/Sophia.psm1 b/src/Sophia_Script_for_Windows_11/Module/Sophia.psm1 index 65ba4b49..b85580c4 100644 --- a/src/Sophia_Script_for_Windows_11/Module/Sophia.psm1 +++ b/src/Sophia_Script_for_Windows_11/Module/Sophia.psm1 @@ -3465,13 +3465,12 @@ function Cursors New-Item -Path "$env:SystemRoot\Cursors\W11_dark_v2.2" -ItemType Directory -Force } - $Parameters = @{ - Path = "$DownloadsFolder\Cursors.zip" - DestinationPath = "$env:SystemRoot\Cursors\W11_dark_v2.2" - Force = $true - Verbose = $true + Add-Type -Assembly System.IO.Compression.FileSystem + $ZIP = [IO.Compression.ZipFile]::OpenRead("$DownloadsFolder\Cursors.zip") + $ZIP.Entries | Where-Object -FilterScript {$_.FullName -like "dark/*.*"} | ForEach-Object -Process { + [IO.Compression.ZipFileExtensions]::ExtractToFile($_, "$env:SystemRoot\Cursors\W11_dark_v2.2\$($_.Name)", $true) } - Expand-Archive @Parameters + $ZIP.Dispose() Remove-Item -Path "$DownloadsFolder\Cursors.zip" -Force @@ -3583,13 +3582,12 @@ function Cursors New-Item -Path "$env:SystemRoot\Cursors\W11_light_v2.2" -ItemType Directory -Force } - $Parameters = @{ - Path = "$DownloadsFolder\Cursors.zip" - DestinationPath = "$env:SystemRoot\Cursors\W11_light_v2.2" - Force = $true - Verbose = $true + Add-Type -Assembly System.IO.Compression.FileSystem + $ZIP = [IO.Compression.ZipFile]::OpenRead("$DownloadsFolder\Cursors.zip") + $ZIP.Entries | Where-Object -FilterScript {$_.FullName -like "light/*.*"} | ForEach-Object -Process { + [IO.Compression.ZipFileExtensions]::ExtractToFile($_, "$env:SystemRoot\Cursors\W11_light_v2.2\$($_.Name)", $true) } - Expand-Archive @Parameters + $ZIP.Dispose() Remove-Item -Path "$DownloadsFolder\Cursors.zip" -Force @@ -10161,10 +10159,10 @@ function HEIF return } - # https://github.com/farag2/Sophia-Script-for-Windows/tree/master/AppX + # https://github.com/farag2/Sophia-Script-for-Windows/tree/master/Misc $DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}" $Parameters = @{ - Uri = "https://github.com/farag2/Sophia-Script-for-Windows/raw/master/AppX/Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx" + Uri = "https://github.com/farag2/Sophia-Script-for-Windows/raw/master/Misc/Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx" OutFile = "$DownloadsFolder\Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx" UseBasicParsing = $true Verbose = $true diff --git a/src/Sophia_Script_for_Windows_11_PowerShell_7/Module/Sophia.psm1 b/src/Sophia_Script_for_Windows_11_PowerShell_7/Module/Sophia.psm1 index 9dd582c2..8bddefa7 100644 --- a/src/Sophia_Script_for_Windows_11_PowerShell_7/Module/Sophia.psm1 +++ b/src/Sophia_Script_for_Windows_11_PowerShell_7/Module/Sophia.psm1 @@ -3467,13 +3467,12 @@ function Cursors New-Item -Path "$env:SystemRoot\Cursors\W11_dark_v2.2" -ItemType Directory -Force } - $Parameters = @{ - Path = "$DownloadsFolder\Cursors.zip" - DestinationPath = "$env:SystemRoot\Cursors\W11_dark_v2.2" - Force = $true - Verbose = $true + Add-Type -Assembly System.IO.Compression.FileSystem + $ZIP = [IO.Compression.ZipFile]::OpenRead("$DownloadsFolder\Cursors.zip") + $ZIP.Entries | Where-Object -FilterScript {$_.FullName -like "dark/*.*"} | ForEach-Object -Process { + [IO.Compression.ZipFileExtensions]::ExtractToFile($_, "$env:SystemRoot\Cursors\W11_dark_v2.2\$($_.Name)", $true) } - Expand-Archive @Parameters + $ZIP.Dispose() Remove-Item -Path "$DownloadsFolder\Cursors.zip" -Force @@ -3585,13 +3584,13 @@ function Cursors New-Item -Path "$env:SystemRoot\Cursors\W11_light_v2.2" -ItemType Directory -Force } - $Parameters = @{ - Path = "$DownloadsFolder\Cursors.zip" - DestinationPath = "$env:SystemRoot\Cursors\W11_light_v2.2" - Force = $true - Verbose = $true + Add-Type -Assembly System.IO.Compression.FileSystem + $ZIP = [IO.Compression.ZipFile]::OpenRead("$DownloadsFolder\Cursors.zip") + $ZIP.Entries | Where-Object -FilterScript {$_.FullName -like "light/*.*"} | ForEach-Object -Process { + [IO.Compression.ZipFileExtensions]::ExtractToFile($_, "$env:SystemRoot\Cursors\W11_light_v2.2\$($_.Name)", $true) } - Expand-Archive @Parameters + $ZIP.Dispose() + Remove-Item -Path "$DownloadsFolder\Cursors.zip" -Force @@ -10199,10 +10198,10 @@ function HEIF return } - # https://github.com/farag2/Sophia-Script-for-Windows/tree/master/AppX + # https://github.com/farag2/Sophia-Script-for-Windows/tree/master/Misc $DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}" $Parameters = @{ - Uri = "https://github.com/farag2/Sophia-Script-for-Windows/raw/master/AppX/Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx" + Uri = "https://github.com/farag2/Sophia-Script-for-Windows/raw/master/Misc/Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx" OutFile = "$DownloadsFolder\Microsoft.HEVCVideoExtension_2.0.51121.0_x64__8wekyb3d8bbwe.Appx" UseBasicParsing = $true Verbose = $true