Gatsby无法通过Starter安装。生成错误

时间:2019-09-10 08:01:14

标签: npm-install gatsby

您好,我想在博客网站上使用gatsby入门工具。但是,当我使用命令gatbsy new [项目名称] [启动URL]时 它显示了这些错误。

fatal error: too many errors emitted, stopping now [-ferror-limit=]
1 warning and 20 errors generated.
make: *** [Release/obj.target/sharp/src/common.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:196:23)
gyp ERR! stack     at ChildProcess.emit (events.js:203:13)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Darwin 18.6.0
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/david/Desktop/blog/node_modules/sharp
gyp ERR! node -v v12.8.1
gyp ERR! node-gyp -v v5.0.3
gyp ERR! not ok
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.7 (node_modules/fsevents):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.7 install: `node install`
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! sharp@0.21.3 install: `(node install/libvips && node install/dll-copy && prebuild-install) || (node-gyp rebuild && node install/dll-copy)`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the sharp@0.21.3 install 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:

 ERROR

Command failed with exit code 1 (EPERM): npm install



  Error: Command failed with exit code 1 (EPERM): npm install

  - error.js:58 makeError
    [lib]/[gatsby-cli]/[execa]/lib/error.js:58:11

  - index.js:112 handlePromise
    [lib]/[gatsby-cli]/[execa]/index.js:112:26

  - task_queues.js:85 processTicksAndRejections
    internal/process/task_queues.js:85:5

我尝试卸载gatsby cli,yarn和npm,但没有成功。 感谢您的任何建议。 而且,当我使用启动器来解决问题时,默认启动器可以正常工作。

0 个答案:

没有答案