|
|
@ -176,6 +176,16 @@ public static string GetString(uint strId) |
|
|
|
# Detect the OS build version |
|
|
|
switch ((Get-CimInstance -ClassName CIM_OperatingSystem).BuildNumber) |
|
|
|
{ |
|
|
|
{$_ -lt 22000} |
|
|
|
{ |
|
|
|
Write-Warning -Message $Localization.UnsupportedOSBuild |
|
|
|
|
|
|
|
Start-Process -FilePath "https://t.me/sophia_chat" |
|
|
|
Start-Process -FilePath "https://discord.gg/sSryhaEv79" |
|
|
|
Start-Process -FilePath "https://github.com/farag2/Sophia-Script-for-Windows#system-requirements" |
|
|
|
|
|
|
|
exit |
|
|
|
} |
|
|
|
{$_ -eq 22000} |
|
|
|
{ |
|
|
|
if (Test-Path -Path "$env:LOCALAPPDATA\PCHealthCheck\PCHealthCheck.exe") |
|
|
@ -273,7 +283,7 @@ public static string GetString(uint strId) |
|
|
|
|
|
|
|
exit |
|
|
|
} |
|
|
|
{($_ -ge 22621) -and ($_ -le 22624)} |
|
|
|
{$_ -eq 22621} |
|
|
|
{ |
|
|
|
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR) -lt 1928) |
|
|
|
{ |
|
|
@ -309,16 +319,6 @@ public static string GetString(uint strId) |
|
|
|
exit |
|
|
|
} |
|
|
|
} |
|
|
|
{$_ -lt 22000} |
|
|
|
{ |
|
|
|
Write-Warning -Message $Localization.UnsupportedOSBuild |
|
|
|
|
|
|
|
Start-Process -FilePath "https://t.me/sophia_chat" |
|
|
|
Start-Process -FilePath "https://discord.gg/sSryhaEv79" |
|
|
|
Start-Process -FilePath "https://github.com/farag2/Sophia-Script-for-Windows#system-requirements" |
|
|
|
|
|
|
|
exit |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
# Check the language mode |
|
|
@ -2301,6 +2301,11 @@ function BrowsingHistory |
|
|
|
$Show |
|
|
|
) |
|
|
|
|
|
|
|
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR) -lt 1928) |
|
|
|
{ |
|
|
|
return |
|
|
|
} |
|
|
|
|
|
|
|
switch ($PSCmdlet.ParameterSetName) |
|
|
|
{ |
|
|
|
"Hide" |
|
|
@ -10906,7 +10911,7 @@ function UninstallUWPApps |
|
|
|
$AppxPackages += Get-AppxPackage -Name Disney.37853FC22B2CE -AllUsers:$AllUsers |
|
|
|
} |
|
|
|
|
|
|
|
$PackagesIds = [Windows.Management.Deployment.PackageManager, Windows.Web, ContentType = WindowsRuntime]::new().FindPackages() | Select-Object -Property DisplayName -ExpandProperty Id | Select-Object -Property Name, DisplayName |
|
|
|
$PackagesIds = [Windows.Management.Deployment.PackageManager]::new().FindPackages() | Select-Object -Property DisplayName -ExpandProperty Id | Select-Object -Property Name, DisplayName |
|
|
|
|
|
|
|
foreach ($AppxPackage in $AppxPackages) |
|
|
|
{ |
|
|
|