Disinstallare più programmi con Winget
Ad essere onesti Windows negli anni ha fatto un pò di cose buone.
Tra le quali c'è sicuramente Winget.
Anche se, sempre ad essere onesti, Winget è dietro millenni luce rispetto a qualsiasi package manager che troviamo su Linux o altri OS.
Ad esempio non è possibile disintallare più programmi insieme.
Per farlo dobbiamo usare uno script.
Qui sotto un esempio che va per nome:
$ids = @(
"Film e TV",
"Fotocamera Windows",
"Microsoft 365 Copilot",
"Outlook for Windows",
"Portale realtà mista",
"PowerToys FileLocksmith Context Menu",
"PowerToys ImageResizer Context Menu",
"PowerToys PowerRename Context Menu",
"Visualizzatore 3D",
"Xbox Identity Provider"
)
foreach ($id in $ids) {
winget uninstall --name $id --silent --accept-source-agreements
}
Io l'ho salvato come winget_remove.ps1; dovete solo lanciarlo da PowerShell.
Se invece volete andare per id:
$ids = @(
"Film e TV",
"Fotocamera Windows",
"Microsoft 365 Copilot",
"Outlook for Windows",
"Portale realtà mista",
"PowerToys FileLocksmith Context Menu",
"PowerToys ImageResizer Context Menu",
"PowerToys PowerRename Context Menu",
"Visualizzatore 3D",
"Xbox Identity Provider"
)
foreach ($id in $ids) {
winget uninstall --id $id --silent --accept-source-agreements
}
Ovviamente nella lista ci dovete mettere gli id dei pacchetti.
Enjoy!
windows winget powershell
Commentami!