
This will grant you the necessary permission to run any executable scripts in your PC’s terminal. Set-ExecutionPolicy -Scope CurrentUser -ExecutionPolicy Unrestricted

Copy and paste the code below and run it. To fix it, open PowerShell as administrator, again make sure to run this in PowerShell, not with the regular command prompt (cmd). Https:/go./fwlink/?LinkID=135170.Īt line:1 char:1 + yarn + ~~~~ + CategoryInfo : SecurityError: (:), PSSecurityException + FullyQualifiedErrorId : UnauthorizedAccess For more information, see about_Execution_Policies at yarn : File C:\Program Files\nodejs\yarn.ps1 cannot be loaded because running scripts is disabled on this system.

If you run into an error with your brand new machine when trying to run any custom scripts like npm, yarn or any node modules you might run into an error similar to below.
