Powershell Error – A parameter cannot be found that matches parameter name ‘AllowPrerelease’.

Error

PS C:\WINDOWS\system32> Install-Module -Name PowerShellGet -AllowPrerelease -Force
Install-Module : A parameter cannot be found that matches parameter name 'AllowPrerelease'.
At line:1 char:36
+ Install-Module -Name PowerShellGet -AllowPrerelease -Force
+                                    ~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (:) [Install-Module], ParameterBindingException
    + FullyQualifiedErrorId : NamedParameterNotFound,Install-Module

Solution

Follow this document

https://www.devopsschool.com/blog/what-is-powershellget-and-how-to-install-powershellget-3-0/

Powershell Error – The term ‘Install-PSResource’ is not recognized as the name of a cmdlet

Error

PS C:\WINDOWS\system32> Install-PSResource -Name PSScriptAnalyzer -Reinstall
Install-PSResource : The term 'Install-PSResource' is not recognized as the name of a cmdlet, function, script file,
or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and
try again.
At line:1 char:1
+ Install-PSResource -Name PSScriptAnalyzer -Reinstall
+ ~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (Install-PSResource:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

Solution

Install-PSResource command is part of PowerShellGet Package which need to be installed first.