我在尝试meanjs时如何解决此npm安装错误?

时间:2019-11-11 09:55:54

标签: nodes npm-install meanjs

当我运行以下命令尝试安装meanjs时:

~/Downloads/mean$ npm install

我遇到以下错误:

  
gyp verb build dir attempting to create "build" dir: /home/arif/Downloads/mean/node_modules/node-sass/build
gyp ERR! configure error 
gyp ERR! stack Error: EACCES: permission denied, mkdir '/home/arif/Downloads/mean/node_modules/node-sass/build'
gyp ERR! System Linux 5.0.0-32-generic
gyp ERR! command "/usr/bin/node" "/home/arif/Downloads/mean/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
gyp ERR! cwd /home/arif/Downloads/mean/node_modules/node-sass
gyp ERR! node -v v11.15.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok 
Build failed with error code: 1
npm WARN ajv-keywords@2.1.1 requires a peer of ajv@^5.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-airbnb@6.0.2 requires a peer of eslint@^2.2.0 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-airbnb@6.0.2 requires a peer of eslint-plugin-react@^4.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.1.2 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.1.2: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/gulp-nodemon/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/glob-watcher/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! node-sass@4.12.0 postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the node-sass@4.12.0 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/arif/.npm/_logs/2019-11-11T09_44_26_049Z-debug.log

我做错了什么,该如何解决?

0 个答案:

没有答案