You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 5, 2024. It is now read-only.
I should see the help output from the nexmo command.
Actual behavior
nexmo : File C:\Users\chris\AppData\Roaming\npm\nexmo.ps1 cannot be loaded because running scripts is disabled on this
system. For more information, see about_Execution_Policies at https:/go.microsoft.com/fwlink/?LinkID=135170.
At line:1 char:1+ nexmo
+ ~~~~~
+ CategoryInfo : SecurityError: (:) [], PSSecurityException
+ FullyQualifiedErrorId : UnauthorizedAccess
This normally occurs when the remote script isn't trusted. I could get it to run by changing my Execution Policy to "RemoteSigned", at which point the CLI worked again:
It looks like at some point after npm 6.9.0, npm started generating a nexmo.ps1 file to help wrap the node SDK in the event node is installed both under Powershell and Linux. This ps1 file will not run under the default "Restricted" execution policy Windows 10 ships with.
npm 6.9.0 and prior do not generate this file, and worked fine.