Today, when I‘m creating a new project in VS2013 it gave me the following error message:
Install failed...Failed to initialize the Powershell host. If your powershell execution policy setting is set to AllSigned, open the package manager console to initialize the host first.
After I had a try, I found out the solution:
1. Run VS2013 as administrator
2. Open "Tools --> NuGet Package Manager --> Package Management Console"
3. Execute command "get-executionpolicy"
4. Execute command "set-executionpolicy unrestricted", if you‘re on 64 bit OS, you should also execute "start-job { set-executionpolicy unrestricted } -runas32 | wait-job | receive-job"
Restart VS, done!
时间: 2024-10-05 08:55:44