Hexo needs to install the hexo-deployer-git plug-in package to create a blog on GitHub.

First of all, I have created a warehouse on GitHub, and then I used git init to initialize the local git warehouse, and then used to add a remote address to the current warehouse, because I need to install a dependency called hexo-deployer-git. I encountered an error when installing this library!
(I used yarn add hexo-deployer-git to install.) The screenshot is as follows:
Insert picture description here

1. Before solving this problem, I first searched the hexo-deployer-git library, which will help us deploy the generated code to a specific branch.
2. Solution :
I will try to use Taobao mirror (if not download Taobao mirror, first run npm install -g cnpm --registry=https://registry.npm.taobao.org to download Taobao mirror): cnpm install hexo-
Insert picture description here
I installed deployer-git --save , but it still reported an error as shown in the figure. I searched on Baidu for a long time and still couldn't find it. When I didn't want to do it, I ran the cnpm install hexo-deployer-git --save command again Now, Insert picture description here
if there are friends who can't download the hexo-deployer-git plugin like me, you can try my above method! ! !

In addition, I also encountered a bug casually mentioned, that is, when I am preparing to submit the code to the git repository, Insert picture description here
the type of deploy in config.yml should be git, and the address in the repo should be http instead of https.

https://www.cnblogs.com/imsoft/p/5228560.html There are other bugs and solutions encountered when hexo creates a warehouse on GitHub.

Guess you like

Origin blog.csdn.net/weixin_46182770/article/details/112277853