解决hexo报错spwan failed

报错1


FATAL {
  err: Error: Spawn failed
      at ChildProcess.<anonymous> (/usr/local/src/hexo/cairbin/node_modules/hexo-util/lib/spawn.js:51:21)
      at ChildProcess.emit (events.js:376:20)
      at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12) {
    code: 128
  }
} Something's wrong. Maybe you can find the solution here: %s https://hexo.io/docs/troubleshooting.html

解决方案

  • 进行以下处理
##进入博客根目录(以我的为例)
cd /usr/local/src/hexo/cairbin/

##删除git提交文件夹
rm -rf .deploy_git/

git config --global core.autocrlf false

  • 最后重新生成提交
hexo clean && hexo g && hexo d

在提交的过程可能又出现以下报错

报错2

! [remote rejected] master -> master (push declined due to email privacy restrictions)

解决方案

  • 这是因为你的github设置出了问题
  • 浏览器进入github.com
  • 登陆github -> "+" ->settings
  • 后续操作如下图

  • 将下方这两个设置取消勾选

  • 重新提交
hexo clean && hexo g && hexo d

大功告成

如果不报错,重新访问页面,就发现已经提交成功了

posted @   CairBin  阅读(6483)  评论(1编辑  收藏  举报
编辑推荐:
· 理解Rust引用及其生命周期标识(上)
· 浏览器原生「磁吸」效果!Anchor Positioning 锚点定位神器解析
· 没有源码,如何修改代码逻辑?
· 一个奇形怪状的面试题:Bean中的CHM要不要加volatile?
· [.NET]调用本地 Deepseek 模型
阅读排行:
· Blazor Hybrid适配到HarmonyOS系统
· Obsidian + DeepSeek:免费 AI 助力你的知识管理,让你的笔记飞起来!
· 分享4款.NET开源、免费、实用的商城系统
· 解决跨域问题的这6种方案,真香!
· 一套基于 Material Design 规范实现的 Blazor 和 Razor 通用组件库
点击右上角即可分享
微信分享提示