This is the 13th day of my participation in Gwen Challenge

Vuepress+GithubPages build personal blog (knowledge notebook) (a), [efficiency tool] build personal static blog -Hugo+Github (two) -, – this article introduces the build personal static blog tool Hugo

Only for reference, according to the need to eat, inadequate, welcome all the big bosses give advice, supplement and improve, welcome to share


  • To do a good job, he must sharpen his tools. Practice promotes the development of science and technology
  • As a siege lion, doing things is also a way to learn, such as setting up their own personal blog, recording daily, recording learning, but also to show themselves to everyone
  • This article will be shared with youhexo + githubBuild your own personal blog to help you increase your knowledge and improve your competitiveness

usehexoCreate a Personal blog

Fast, simple and efficient blogging framework

[documentation] : Hexo

【 theme 】 : Hexo theme

Gihub /gohugoio/ Hugo

  • Superfast Node.js allows hundreds of pages to be rendered instantly in a matter of seconds.

  • Markdown Support Hexo supports all of the GitHub Markdown features and even integrates most of Octopress’s plugins.

  • One-click deployment can be deployed to GitHub Pages, Heroku or other platforms with a single command.

  • Plugins and a powerful extensible API bring endless possibilities and easy integration with several template engines (EJS, Pug, Nunjucks) and tools (Babel, PostCSS, Less/Sass)

Build personal blog based on Hexo + Markdown. Easy to build, relatively complete and mature ecology, comprehensive problem solutions

Here is the introduction/installation/setup/theme change/deployment to Github

usehexoCreate a blog

1. Installnodejs / hexo

# Taobao Mirror source
npm install -g --registry=https://registry.npm.taobao.org

# installation hexo
cnpm i hexo-cli -g
# validation hexo
hexo -v
# # hexo: 3.9.0
# # hexo - cli: 2.0.0
# # node: 10.16.0
Copy the code

2. The hexo command creates the project

Create a project folder CD Run the following command:

Initialize the project
hexo init
# default to clone a landscape theme: themes/landscape;
Source /_posts/hello-world.md
Enter the project root directory, hexo start
# ==> Short for hexo s
hexo s
Copy the code

3. Create your first blog

# n => new
# ./source/_posts/my-first-blog.md
hexo n 'Article name: e.g. My-first-blog'
hexo n 'my-first-blog'
Copy the code

Create a Page (Important)

The tags folder will be created under the source folder in the root directory
hexo new page "tags"
Copy the code

4. Change the theme

# Clone the theme and place it in the Themes directory under < theme name folder >
# The following is the theme of 'yilia'
git clone https://github.com/litten/hexo-theme-yilia.git themes/yilia
Copy the code

Modifying configurations

# Extensions
## Plugins: https://hexo.io/plugins/
## Themes: https://hexo.io/themes/
# themes/< themes >
theme: yilia # the default landscape
Copy the code
Clear the #
hexo clean
# INFO Deleted database.
# INFO Deleted public folder.
Copy the code

5. Deployedgihub-pages

Use the git plug-in hexo-deployer-git

# Project directory installation
cnpm i --save hexo-deployer-git
Copy the code

Modify the following configuration in the project configuration file _config.yml

# Deployment
## Docs: https://hexo.io/docs/deployment.html
deploy:
  # type uses Git deployment
  type: git
  # github address
  repo: https://github.com/<username>/<proname>.git
  # github project branch (default: master
  branch: master
Copy the code
# deploy command: hexo deploy for short 'hexo d
hexo d
Copy the code

You can also use Github Actions to help you automate your build, as suggested in the previous section


Of course, there are many useful tools for building blogs. Here are some of them for reference only.

You can find and use your favorite theme, you can also customize your own theme, there is no get it?

Welcome to comment on your secret tools and share your blog with everyone =, =

Today’s preview will not be updated tomorrow, no ideas/topics:

Since the update of today’s article is a little late, I haven’t decided on the topic for tomorrow’s update, so let’s rest early and think about it tomorrow

Go to bed early, everybody good dream! Stay tuned for the next post! hahah~