Hexo 配置过程记录

错误 1

问题:使用 git 部署 hexo 时报错:ERROR Deployer not found: git

背景

按照 Hexo 官方一键部署教程(在 GitHub Pages 上部署 Hexo | Hexo)执行部署命令时,出现如下错误:
参考官方教程时出现报错

解决思路

搜索后得知该问题是说我一键部署 Hexo 需要的 hexo-deployer-git 没有安装。但是我在安装 Hexo 目录已经安装成功了 hexo-deployer-git。思考后联想到最开始新建项目时Hexo提示了一个错误:
新建 Hexo 时出现的错误

所以猜想:可能是因为我的项目并不在根目录,执行部署操作需要在项目目录下,而我之前安装的 hexo-deployer-git 安装在了根目录,部署时 hexo 无法去根目录下找我的 deployer。

考虑可以使用cnpm指令,已有博客尝试该做法:

搭建个人博客安装一键部署插件 npm install hexo-deployer-git –save 的问题(Hexo框架)

按照该帖操作,问题解决。

​错误 2

问题:hexo 发布到 GitHub 出现 404

在 hexo 部署到 GitHub Pages 后,访问网址出现404错误。

解决方法:
https://blog.csdn.net/jerry81smile/article/details/132666321

Donate
  • Copyright: Copyright is owned by the author. For commercial reprints, please contact the author for authorization. For non-commercial reprints, please indicate the source.

扫一扫,分享到微信

微信分享二维码
  • Copyrights © 2024 Piper Shi
  • Visitors: | Views:

请我喝杯咖啡吧~