Skip to content

Instantly share code, notes, and snippets.

@d4rkeagle65
Created January 2, 2020 15:49
Show Gist options
  • Save d4rkeagle65/6b0a2d0edd203ef7ba9a6ea81983d3cb to your computer and use it in GitHub Desktop.
Save d4rkeagle65/6b0a2d0edd203ef7ba9a6ea81983d3cb to your computer and use it in GitHub Desktop.
Small PowerShell script to disable Windows Content Delivery Management, allowing apps to be uninstalled permanently.
$reg_cdm = '\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager'
$keys = Get-Item -Path ("HKCU:"+$reg_cdm))
$keys.GetValueNames() | Foreach-Object {
If ($keys.GetValueKind($_) -eq 'DWord') {
Set-ItemProperty -Path ('HKCU:'+$reg_cdm) -Name $_ -Value 0 -Force
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment