current position:Home>Hexo quickly set up its own blog

Hexo quickly set up its own blog

2022-04-29 10:17:21Dada front end

Many people have their own blogs , So do you want ? utilize Hexo You can build your own blog . Characteristic is Hexo Is a static website , So let's teach you how to build .

One : download Git:  

I taught you a little bit earlier Git Basic tutorials for , You can check the history to find out .

Two : download Node.js:

Just download it directly and install it soon .

3、 ... and : Have your own Github account number , Good configuration Github, The library is

Four : install Hexo

open Git Bash Enter the command : npm install -g hexo

Then you create a folder , Run in this directory Git Bash, Input :hexo init that will do , In the input npm install

After the installation, you can see Hexo Catalog , But you need to know which path to download , Easy to find .

Click to enter hexo Catalog

If so, you will succeed .

Get into _config.yml To configure

Find the following code :

deploy:   type: git   repo: Your new github Address .git   branch: master ( Add this , There is nothing in it )

See... In the directory themes , You can change the theme : I use it next , To facilitate the provision of links :

Then after you change the theme , stay _config.yml , Just change the theme .

5、 ... and : Run to see the effect :

hexo clean

hexo generate

hexo server ( At this command , Open the browser :http://localhost:4000)

You can view the operation effect *_*

hexo deploy ( This is to submit the code to github Webpage , You can enter your address on the web page .

copyright notice
author[Dada front end],Please bring the original link to reprint, thank you.

Random recommended