Automate Windows Update
Run from an elevated PowerShell session.
Set-ExecutionPolicy RemoteSigned
Install-Module -Name PSWindowsUpdate
Add-WUServiceManager -MicrosoftUpdate
Install-WindowsUpdate -MicrosoftUpdate -AcceptAll
Note: this will not reboot the system when it’s done — schedule a reboot separately if needed.
See also: Chocolatey Setup and Use, Check if a Windows Update is Installed