Vue.js 命令';vue';未找到Ubuntu 18.04

Vue.js 命令';vue';未找到Ubuntu 18.04,vue.js,ubuntu,npm,yarnpkg,vue-cli,Vue.js,Ubuntu,Npm,Yarnpkg,Vue Cli,我已经在全球安装了nodejsv10.19.0 我首先有npm(在我的项目分支和根上): valentin@valentin:~$npm i-g@vue/cli npm警告弃用的内核-js@2.6.11:核心-js@I希望您已经检查了这些线程,@AmitP我已经检查了第一个线程,但是我还没有看到第二个线程。希望这能为我指明正确的方向。我以后会告诉你的。谢谢@AmitP更新我的路径命令确实有帮助。虽然我在这一次之前看到过这条线索,但我更加关注它(在这个问题上提出的解决方案太多了,所以我被许多其他来

我已经在全球安装了nodejs
v10.19.0

我首先有npm(在我的项目分支和根上):

valentin@valentin:~$npm i-g@vue/cli

npm警告弃用的内核-js@2.6.11:核心-js@I希望您已经检查了这些线程,@AmitP我已经检查了第一个线程,但是我还没有看到第二个线程。希望这能为我指明正确的方向。我以后会告诉你的。谢谢@AmitP更新我的路径命令确实有帮助。虽然我在这一次之前看到过这条线索,但我更加关注它(在这个问题上提出的解决方案太多了,所以我被许多其他来回的问题分散了注意力)。非常感谢。更新路径变量有帮助
valentin@valentin:~$ npm i -g @vue/cli
npm WARN deprecated core-js@2.6.11: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
npm WARN rm not removing /home/valentin/.npm-global/bin/vue as it wasn't installed by /home/valentin/.npm-global/lib/node_modules/@vue/cli
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.11 (node_modules/@vue/cli/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.11: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

npm ERR! code EEXIST
npm ERR! syscall symlink
npm ERR! path ../lib/node_modules/@vue/cli/bin/vue.js
npm ERR! dest /home/valentin/.npm-global/bin/vue
npm ERR! errno -17
npm ERR! EEXIST: file already exists, symlink '../lib/node_modules/@vue/cli/bin/vue.js' -> '/home/valentin/.npm-global/bin/vue'
npm ERR! File exists: /home/valentin/.npm-global/bin/vue
npm ERR! Remove the existing file and try again, or run npm
npm ERR! with --force to overwrite files recklessly.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/valentin/.npm/_logs/2020-02-08T10_36_35_054Z-debug.log
valentin@valentin:~$ npm i -g @vue/cli --force
npm WARN using --force I sure hope you know what you are doing.
npm WARN deprecated core-js@2.6.11: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
/home/valentin/.npm-global/bin/vue -> /home/valentin/.npm-global/lib/node_modules/@vue/cli/bin/vue.js

> fsevents@1.2.11 install /home/valentin/.npm-global/lib/node_modules/@vue/cli/node_modules/fsevents
> node-gyp rebuild

make: Entering directory '/home/valentin/.npm-global/lib/node_modules/@vue/cli/node_modules/fsevents/build'
  SOLINK_MODULE(target) Release/obj.target/.node
  COPY Release/.node
make: Leaving directory '/home/valentin/.npm-global/lib/node_modules/@vue/cli/node_modules/fsevents/build'

> core-js@2.6.11 postinstall /home/valentin/.npm-global/lib/node_modules/@vue/cli/node_modules/babel-polyfill/node_modules/core-js
> node -e "try{require('./postinstall')}catch(e){}"

Thank you for using core-js ( https://github.com/zloirock/core-js ) for polyfilling JavaScript standard library!

The project needs your help! Please consider supporting of core-js on Open Collective or Patreon: 
> https://opencollective.com/core-js 
> https://www.patreon.com/zloirock 

Also, the author of core-js ( https://github.com/zloirock ) is looking for a good job -)


> core-js@2.6.11 postinstall /home/valentin/.npm-global/lib/node_modules/@vue/cli/node_modules/babel-runtime/node_modules/core-js
> node -e "try{require('./postinstall')}catch(e){}"


> core-js@3.6.4 postinstall /home/valentin/.npm-global/lib/node_modules/@vue/cli/node_modules/core-js
> node -e "try{require('./postinstall')}catch(e){}"


> @apollo/protobufjs@1.0.3 postinstall /home/valentin/.npm-global/lib/node_modules/@vue/cli/node_modules/@apollo/protobufjs
> node scripts/postinstall


> nodemon@1.19.4 postinstall /home/valentin/.npm-global/lib/node_modules/@vue/cli/node_modules/nodemon
> node bin/postinstall || exit 0


> ejs@2.7.4 postinstall /home/valentin/.npm-global/lib/node_modules/@vue/cli/node_modules/ejs
> node ./postinstall.js

Thank you for installing EJS: built with the Jake JavaScript build tool (https://jakejs.com/)

+ @vue/cli@4.2.2
added 1178 packages from 661 contributors in 40.25s
valentin@valentin:~$ vue --version

Command 'vue' not found, did you mean:

  command 'vpe' from deb texlive-latex-extra

Try: sudo apt install <deb name>



valentin@valentin:~/code/Vue.js/Vue Mastery/Real World Vue.js$ npm i core-js

> core-js@3.6.4 postinstall /home/valentin/code/Vue.js/Vue Mastery/Real World Vue.js/node_modules/core-js
> node -e "try{require('./postinstall')}catch(e){}"

npm WARN saveError ENOENT: no such file or directory, open '/home/valentin/code/Vue.js/Vue Mastery/Real World Vue.js/package.json'
npm WARN enoent ENOENT: no such file or directory, open '/home/valentin/code/Vue.js/Vue Mastery/Real World Vue.js/package.json'
npm WARN Real World Vue.js No description
npm WARN Real World Vue.js No repository field.
npm WARN Real World Vue.js No README data
npm WARN Real World Vue.js No license field.

+ core-js@3.6.4
updated 1 package and audited 469 packages in 1.471s

3 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities
valentin@valentin:~$ npm outdated
Package                Current  Wanted  Latest  Location
@vue/babel-preset-app    4.1.0   4.2.2   4.2.2  global
valentin@valentin:~$ yarn global add @vue/cli
yarn global v1.21.1
[1/4] Resolving packages...
[2/4] Fetching packages...
info fsevents@1.2.11: The platform "linux" is incompatible with this module.
info "fsevents@1.2.11" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
[4/4] Building fresh packages...

success Installed "@vue/cli@4.2.2" with binaries:
      - vue
Done in 2.65s.
valentin@valentin:~$ vue --version

Command 'vue' not found, did you mean:

  command 'vpe' from deb texlive-latex-extra

Try: sudo apt install <deb name>