how to update powershell version
#Using the WinGet package manager winget install --id=Microsoft.PowerShell -e
powershell update help
Update-help #Type this into powershell and press 'enter' and the update will begin running #This will only update the help file that you see when running 'get-help' #It will NOT update all of powershell
update powershell
Invoke-Expression "& { $(Invoke-Restmethod https://aka.ms/Install-PowerShell.ps1) } -UseMSI"
Source: pscustomobject.github.io
update powershell
Invoke-Expression "& { $(irm https://aka.ms/install-powershell.ps1) } -UseMSI"
Source: markcerv.com
powershell upgrade
winget upgrade powershell
Source: www.delftstack.com