vue-element-admin運行npm install 報錯
npm ERR! code 128
npm ERR! An unknown git error occurred
npm ERR! command git --no-replace-objects ls-remote ssh://git@github.com/nhn/raphael.git
npm ERR! git@github.com: Permission denied (publickey).
npm ERR! fatal: Could not read from remote repository.
npm ERR!
npm ERR! Please make sure you have the correct access rights
npm ERR! and the repository exists.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\17605\AppData\Local\npm-cache\_logs\2022-03-21T10_41_46_956Z-debug.log
嘗試了好幾種辦法,修改.gitconfig文件,配置過tb鏡像,也重新配置過GitHub的ssh,還是未能解決,最后看見一篇直接刪除依賴的,刪除完了就解決了。
原文:https://juejin.cn/post/6979047498941726750
下面是修改了一下的,只需要刪除這些也是可以安裝了的,
1、打開package.json把"tui-editor"刪掉
2、刪除"tui-editor"相關路由、components,具體文件地址如下:
路由位置: src/router/modules/components.js 搜索markdown,把相應路由代碼刪除
components位置:
src/components/MarkdownEditor
刪除后,再執行npm install 或 npm install --registry=registry.npm.taobao.org 下載並運行成功!
vue-admin-template簡潔版可以直接npm install運行成功
vue-element-admin加強版的卻運行報錯的,后續找到方法了再來更新。。。