-
-
Notifications
You must be signed in to change notification settings - Fork 6.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Vue CLI fails on Windows Powershell #3424
Comments
Duplicate of #3293 and it is a bug of yarn yarnpkg/yarn#6902 |
The title of this issue is much more clear than the one of the other duplicate. Also, I don't speak chinese :) Thanks for the info. The temporary solution is to roll back to yarn |
It might be slightly misleading to use NPM in the "Steps to reproduce" when the issue is related to a specific version of Yarn. Also, to circumvent the issue until it is fixed, you can just call the |
I don't know if this is your issue, but I just removed it globally with yarn and re-installed it globally with npm (via admin). Everything works perfectly now; a .ps1 file was not downloaded, leaving the .cmd as the only option. npm i --global vue-cli This was giving me a major headache for the past 45 minutes... |
I confirm that vue-cli breaks on yarn tldr: unless someone wants/is skilled enough to contribute on official yarnpkg for windows, the issue will remain |
Tengo el mismo problema y no lo he podido solucionar así |
This issue seems to have reared its head again, but this time - nothing to do with Yarn. I was bashing my head against the wall because all searches point to Yarn - but:
I don't have Yarn in my system, and installed Vue/CLI with NPM. I get this issue. Renaming the vue.ps1 to something else so the "Vue" call uses the .cmd file fixes the issue - but out of the box, the vue cli will not work in PowerShells (the default inside the VS IDE, so that's definitely an issue). |
I have the same issue today on a clean system |
You can navigate to where the global vue-cli is installed and delete the vue.ps1 file, leaving the vue.cmd file – then things work fine. It’s a work-around for now, I guess.
From: Domenico Maresca<mailto:notifications@github.com>
Sent: Thursday, November 28, 2019 4:33 AM
To: vuejs/vue-cli<mailto:vue-cli@noreply.github.com>
Cc: jason-e-gross<mailto:jason.e.gross@outlook.com>; Comment<mailto:comment@noreply.github.com>
Subject: Re: [vuejs/vue-cli] Vue CLI fails on Windows Powershell (#3424)
vue : File C:\Users\jason\AppData\Roaming\npm\vue.ps1 cannot be loaded. The file C:\Users\jason\AppData\Roaming\npm\vue.ps1 is not digitally signed. You cannot run this script on the current system. For more information about running scripts and setting execution policy, see about_Execution_Policies at https:/go.microsoft.com/fwlink/?LinkID=135170. At line:1 char:1
This issue seems to have reared its head again, but this time - nothing to do with Yarn. I was bashing my head against the wall because all searches point to Yarn - but:
1. Remove Node from system entirely, deleting global module folders, also.
2. Reinstall Node.
3. "npm install -g @vue/cli" - let it do its thing
4. Type "Vue" on a powershell window, and you get the error above.
I don't have Yarn in my system, and installed Vue/CLI with NPM. I get this issue. Renaming the vue.ps1 to something else so the "Vue" call uses the .cmd file fixes the issue - but out of the box, the vue cli will not work in PowerShells (the default inside the VS IDE, so that's definitely an issue).
I have the same issue today on a clean system
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub<#3424?email_source=notifications&email_token=AD54Y7CFQHOF2ZMFLNL6CPLQV6NADA5CNFSM4GURRP4KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEFMFSZI#issuecomment-559438181>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AD54Y7BQFGC6IJKMKJ377YTQV6NADANCNFSM4GURRP4A>.
|
my work-around: Set-ExecutionPolicy -ExecutionPolicy Unrestricted -Scope CurrentUser |
@Hooponopono THANK YOU SO MUCH! That's all I needed, no reinstall nor any other acrobatics ;) |
run this command: |
Thank you! |
Thanx! |
Having the same Issue, thanks to @Hooponopono. This tip fixed the problem. |
Oh! It's working, Thank You Man |
This one is better since the scope is limited to the current shell. The other proposal seams to disable security checks for the whole user. |
thanks for your great answer, That's all I needed😀 |
Thank you man , you save me 😀 . |
hello, thanks for the silution but...is there a "less workaround" solution? |
this is work for me. thanks |
What I had to do on Windows 11 (and maybe applies to 10): |
Instead of using PowerShell and allow that Policy which may cause a security problem I have useed GitBash and it worked for me |
thank you ,this help me |
ty, this method works for me. |
so becially I've to memorize that command because everytime I exit the vscode, it's the same error again unless i hit that command again |
This worked great with me when using VSCode |
Gracias @Hooponopono!!!! |
Version
3.4.0
Environment info
Steps to reproduce
Install Vue CLI using npm by running
npm i -g @vue/cli
Open powershell as either standard or admin user.
run
vue create test
in powershellWhat is expected?
Vue should run its cli to create a new project without errors
What is actually happening?
Vue CLI fails in only powershell due to apparent syntax errors.
It appears to work fine in cmd.
The text was updated successfully, but these errors were encountered: