【发布时间】:2019-10-31 18:37:56
【问题描述】:
我在 www.gatsbyjs.org/packages/gatsby-source-tumblr/ 找到了 gatsby-source-tumblr,并决定试一试,因为我在 tumblr 上有图片,我想在我的 gatsby 网站上展示。
但是,它不会安装。
这是错误:
npm ERR! path C:\Users\christoffer.rydestah\Documents\Repos\napoli-cafe\node_modules\.bin\json5.cmd
npm ERR! code EEXIST
npm ERR! Refusing to delete C:\Users\christoffer.rydestah\Documents\Repos\napoli-cafe\node_modules\.bin\json5.cmd: ..\@babel\core\node_modules\json5\lib\cli.js symlink target is not controlled by npm C:\Users\christoffer.rydestah\Documents\Repos\napoli-cafe\node_modules\json5
npm ERR! File exists: C:\Users\christoffer.rydestah\Documents\Repos\napoli-cafe\node_modules\.bin\json5.cmdnpm ERR! Move it away, and try again.
npm ERR! A complete log of this run can be found in:npm ERR! C:\Users\christoffer.rydestah\AppData\Roaming\npm-cache\_logs\2019-10-31T08_56_28_688Z-debug.logC:\Users\christoffer.rydestah\Documents\Repos\napoli-cafe>sudo npm install --save gatsby-source-tumblr
'sudo' is not recognized as an internal or external command,operable program or batch file.
有人遇到过这个插件的问题吗? 任何想法如何解决这个问题?
【问题讨论】:
-
删除你的 node_modules 并运行
npm i再次检查,不要使用 sudo 运行任何东西 -
@Pardeep 这个问题来自
window。 -
我只看到 'sudo' 未被识别为内部或外部命令:P
-
@KingStone 是对的,这是窗口问题。尝试在我的 macbook 上安装该插件,并且成功了。