3.7.0
System:
OS: Linux 4.15 Ubuntu 18.04.2 LTS (Bionic Beaver)
CPU: (8) x64 Intel(R) Core(TM) i7-8550U CPU @ 1.80GHz
Binaries:
Node: 8.10.0 - /usr/bin/node
Yarn: 1.16.0 - /usr/local/bin/yarn
npm: 3.5.2 - /usr/bin/npm
Browsers:
Chrome: 74.0.3729.108
Firefox: Not Found
npmGlobalPackages:
@vue/cli: 3.7.0
$ npm init
$ npm install @vue/cli
(? i may have used "yarn" in between)
$ vue create myproject
the create process appears
00h00m00s 0/0: : ERROR Error: Command failed: yarn config get registry
ERROR: [Errno 2] No such file or directory: 'config'
Error: Command failed: yarn config get registry
ERROR: [Errno 2] No such file or directory: 'config'
at makeError (/usr/local/lib/node_modules/@vue/cli/node_modules/execa/index.js:174:9)
at Promise.all.then.arr (/usr/local/lib/node_modules/@vue/cli/node_modules/execa/index.js:278:16)
at <anonymous>
at process._tickCallback (internal/process/next_tick.js:188:7)
this can be a setup process issue as I'm still learning the nodejs ecosystem. But it appeared every time I executed it wherever I installed vue in.
despite running the create command with npm, vue-cli will try to use yarn to install the packages for that new projec for you - if it's installed. (We can't detect how you ran the create
command so can't deduce from that).
Since you appearantly have yarn installed, it tries to use yarn, but fails since your yarn config / installation seems broken?
You should check to see if running yarn config get registry
works in your terminal.
Assuming yarn installation really is broken and you don't succeed in fixing it, as a workaround you can
a) uninstall yarn so create
will fall back to npm
b) explictly tell it to use npm:
vue create myproject --packageManager npm
Another workaround:
vue config -s packageManager npm
Closing due to inactivity.
@sodatea Use the need feedback
label and the stale bot will kick in.
@Akryum Ahh I thought it was "stale" and failed to find one. Will definitely use it next time.
Following this post worked for me.
https://github.com/yarnpkg/yarn/issues/3708#issuecomment-317358958
sudo apt-get -o Dpkg::Options::="--force-overwrite" install yarn
Uninstall yarn by
sudo apt remove cmdtest
sudo apt remove yarn
Same problem for me. I've just removed yarn from my system.
sudo rm -rf /usr/bin/yarn
This usually happens on Ubuntu since yarn
on Ubuntu is cmdtest
and yarnpkg
is the actual yarn we want. Is there any way to detect the OS and choose the right command?
Most helpful comment
despite running the create command with npm, vue-cli will try to use yarn to install the packages for that new projec for you - if it's installed. (We can't detect how you ran the
create
command so can't deduce from that).Since you appearantly have yarn installed, it tries to use yarn, but fails since your yarn config / installation seems broken?
You should check to see if running
yarn config get registry
works in your terminal.Assuming yarn installation really is broken and you don't succeed in fixing it, as a workaround you can
a) uninstall yarn so
create
will fall back to npmb) explictly tell it to use npm: