【发布时间】:2020-09-29 04:02:34
【问题描述】:
我是编程新手,在尝试安装 parcel.js 时遇到了一些困难
这是我遇到的错误:
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 deprecated chokidar@2.1.8: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
npm WARN deprecated fsevents@1.2.13: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade to fsevents 2.
npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm ERR! code EACCES
npm ERR! syscall symlink
npm ERR! path ../lib/node_modules/parcel-bundler/bin/cli.js
npm ERR! dest /usr/local/bin/parcel
npm ERR! errno -13
npm ERR! Error: EACCES: permission denied, symlink '../lib/node_modules/parcel-bundler/bin/cli.js' -> '/usr/local/bin/parcel'
npm ERR! [OperationalError: EACCES: permission denied, symlink '../lib/node_modules/parcel-bundler/bin/cli.js' -> '/usr/local/bin/parcel'] {
npm ERR! cause: [Error: EACCES: permission denied, symlink '../lib/node_modules/parcel-bundler/bin/cli.js' -> '/usr/local/bin/parcel'] {
npm ERR! errno: -13,
npm ERR! code: 'EACCES',
npm ERR! syscall: 'symlink',
npm ERR! path: '../lib/node_modules/parcel-bundler/bin/cli.js',
npm ERR! dest: '/usr/local/bin/parcel'
npm ERR! },
npm ERR! errno: -13,
npm ERR! code: 'EACCES',
npm ERR! syscall: 'symlink',
npm ERR! path: '../lib/node_modules/parcel-bundler/bin/cli.js',
npm ERR! dest: '/usr/local/bin/parcel'
npm ERR! }
npm ERR!
npm ERR! The operation was rejected by your operating system.
npm ERR! It is likely you do not have the permissions to access this file as the current user
npm ERR!
npm ERR! If you believe this might be a permissions issue, please double-check the
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/cavingayle/.npm/_logs/2020-06-09T20_46_00_855Z-debug.log
【问题讨论】:
-
Calvin,您能告诉我们您使用的是什么操作系统吗?我认为您应该尝试以提升的权限运行此命令。
-
嗨 Christopher,我目前正在运行 mac OS Catalina。我很抱歉,但怎么可能以提升的权限运行
-
在命令前加上 sudo;例如,sudo npm install xxx
标签: node.js npm npm-install parcel parceljs