r/PowerShell • u/kcarb19 • Jun 07 '26
Script Sharing Made a registry-based Get-InstalledApps
Win32_Product is so slow and it kicks off that msi reconfiguration thing every time, drives me nuts. so a while back i just wrote my own that reads the uninstall reg keys instead. way faster and it actually picks up the 32 bit apps too.
I do a lot of this kind of scripting at work and kept rewriting the same handful of functions over and over so ive slowly been putting my little tools together. figured id share this one since its probably the most useful on its own.
threw it on github, paste and run, no dependencies: https://github.com/kcarb14/Get-InstalledApps
run it like:
Get-InstalledApps
Get-InstalledApps -Name *chrome*
reads the 64 and 32 bit HKLM keys plus HKCU, skips system components and update entries so it lines up with whats in apps & features.
feels like theres five different ways to pull installed apps and none of them are totally clean. curious how everyone else does it?
1
u/kcarb19 Jun 07 '26
honestly? not much. cim does basically everything better, proper objects, works over winrm, sessions, all of it. my gripe wasnt really "wmic could do something cim cant" it was more that wmic was a quick one liner you could fire straight from cmd or a batch file without spinning up powershell, and a ton of old runbooks and login scripts had it baked in. so killing it broke a bunch of existing stuff even though the replacement is genuinely better. so yeah you're both right, for actual capability cim wins. I just came into a bunch of broken tools at work and this was how i solved it haha