简体   繁体   English

Vue CLI 项目设置抛出 ENOENT: no such file or directory 错误

[英]Vue CLI project setup throws ENOENT: no such file or directory error

I am trying to create a new Vue.js app and I am running the command:我正在尝试创建一个新的 Vue.js 应用程序,我正在运行命令:

vue create client

Next I am selecting the default template:接下来我选择默认模板:

default (babel, eslint) 

However, before the setup completes, it exits with the following error:但是,在设置完成之前,它会退出并出现以下错误:

✨  Creating project in /workspace/client.
⚙️  Installing CLI plugins. This might take a while...

npm ERR! code ENOENT
npm ERR! syscall rename
npm ERR! path /workspace/client/node_modules/.inquirer.DELETE/node_modules/ansi-styles
npm ERR! dest /workspace/client/node_modules/inquirer/node_modules/ansi-styles
npm ERR! errno -2
npm ERR! enoent ENOENT: no such file or directory, rename '/workspace/client/node_modules/.inquirer.DELETE/node_modules/ansi-styles' -> '/workspace/client/node_modules/inquirer/node_modul
es/ansi-styles'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent 

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2020-04-29T20_47_33_239Z-debug.log

I am developing inside a docker container with node 12.我正在使用节点 12 的 docker 容器内进行开发。
My question is: how can I fix this issue?我的问题是:我该如何解决这个问题? Also, is this a Docker-related issue?另外,这是与 Docker 相关的问题吗?

Reinstall Node.js and then try to install Vue https://nodejs.org/en/重新安装 Node.js 然后尝试安装 Vue https://nodejs.org/en/

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM