Remediation script #2593
-
Hello guys. I like this tool and would like to set it up for my small org. I use Intune and was thinking about deploying a remediation script to work on a schedule: 1: open UnigetUI as admin Is it possible at all? if not, can you guide me on what should be the best approach to solve this problem? I am a bit lost here and don't have a deep knowledge of PowerShell scripts but can find my way around. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
You don't need UniGetUI - you can do that directly with winget powershell's module. What UniGetUI is doing is provide a UI to the underlying command line tools that you can already use. Example code to collect the installed packages and list which are ready for updates: $wgupd = Get-WinGetPackage -OutVariable wglist | Where-Object { $_.IsUpdateAvailable }
Write-Host "Packages $($wglist.Count); Updates $($wgupd.Count)"
$wgupd | Sort-Object Name And then update everything except packages that match either 'not-this-package' or 'bad-name' $wgupd | Where-Object Id -NotMatch 'not-this-package|bad-name' | Update-WinGetPackage -Verbose |
Beta Was this translation helpful? Give feedback.
-
@Lockszmith-GH is right. UniGetUI is not designed for automated tasks, WinGet is much more appropiate instead |
Beta Was this translation helpful? Give feedback.
You don't need UniGetUI - you can do that directly with winget powershell's module.
Or if you prefer chocolatey or scoop, use that instead.
What UniGetUI is doing is provide a UI to the underlying command line tools that you can already use.
Example code to collect the installed packages and list which are ready for updates:
And then update everything except packages that match either 'not-this-package' or 'bad-name'