mirror of
https://github.com/Raphire/Win11Debloat.git
synced 2026-02-20 09:26:25 +00:00
Compare commits
3 Commits
2026.02.18
...
2026.02.19
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ea67435f64 | ||
|
|
a611e6b128 | ||
|
|
033fa1b8af |
@@ -97,7 +97,7 @@ param (
|
||||
|
||||
|
||||
# Define script-level variables & paths
|
||||
$script:Version = "2026.02.18"
|
||||
$script:Version = "2026.02.19"
|
||||
$script:DefaultSettingsFilePath = "$PSScriptRoot/DefaultSettings.json"
|
||||
$script:AppsListFilePath = "$PSScriptRoot/Apps.json"
|
||||
$script:SavedSettingsFilePath = "$PSScriptRoot/LastUsedSettings.json"
|
||||
@@ -185,7 +185,7 @@ catch {
|
||||
|
||||
# Check if WinGet is installed & if it is, check if the version is at least v1.4
|
||||
try {
|
||||
if ([int](((winget -v) -replace 'v','').split('.')[0..1] -join '') -gt 14) {
|
||||
if (Get-Command winget -ErrorAction SilentlyContinue) {
|
||||
$script:WingetInstalled = $true
|
||||
}
|
||||
else {
|
||||
@@ -193,6 +193,7 @@ try {
|
||||
}
|
||||
}
|
||||
catch {
|
||||
Write-Error "Unable to determine if WinGet is installed, winget command failed: $_"
|
||||
$script:WingetInstalled = $false
|
||||
}
|
||||
|
||||
@@ -508,7 +509,7 @@ function RemoveApps {
|
||||
}
|
||||
else {
|
||||
# Uninstall app via WinGet
|
||||
winget uninstall --accept-source-agreements --disable-interactivity --id $app
|
||||
$wingetOutput = winget uninstall --accept-source-agreements --disable-interactivity --id $app
|
||||
|
||||
If (($app -eq "Microsoft.Edge") -and (Select-String -InputObject $wingetOutput -Pattern "Uninstall failed with exit code")) {
|
||||
Write-ToConsole "Unable to uninstall Microsoft Edge via WinGet" -ForegroundColor Red
|
||||
|
||||
Reference in New Issue
Block a user