ERROR Deployer not found:git

在使用 Hexo 进行网站部署时,遇到“ERROR Deployer not found: git”错误是比较常见的问题。该错误通常由以下几个原因引起,并且有相应的解决方法:

Git 未安装:确保你的电脑上已经安装了 Git。如果没有安装,可以通过以下命令在终端中安装 Git:



sudo apt-get install git  
  

Git 未配置:确保你的 Git 已经正确配置。可以通过以下命令检查 Git 配置:



git config --global user.name "Your Name"  
git config --global user.email "youremail@example.com"  
  

未安装 hexo-deployer-git 插件:确保你的 Hexo 已经安装了 hexo-deployer-git 插件。CD 到博客根目录,通过以下命令安装 hexo-deployer-git 插件:



npm install hexo-deployer-git --save  
  

添加新评论