Step by step guide to create a blog using Hexo!
Check documentation for more info.
Find most of your answers in troubleshooting or ask on GitHub.
Quick Start
Prerequisites
Visual studio code
Github account
Install git
Install node.js
Create a folder say c:\Hexo on your machine, and open the folder in VSCode, then follow below steps
Install Hexo
Open command prompt ctrl+` and execute
Once installed Hexo, check the hexo installation using below command
|
|
Create a blog
|
|
Create a new post
|
|
More info: Writing
See the blog
|
|
More info: Server
Open browser and type http://localhost:4000 to see your blog
Preview Drafts
|
|
Any static files under the _drafts folder will be available to preview on localhost site only
Generate static files
|
|
More info: Generating
Deployment using github account
Create a github repository
For my account sunilpatro1985, I will create a repository as sunilpatro1985.github.io
Note: Select public and add.gitignore as Node
Site url will be now https://sunilpatro1985.github.io
but we are not done yet, we have to deploy our blog to git
|
|
Get the repository weburl from github (on the github repository, click on clone or download button and copy the web url)
Now on the _config.yaml file, update the deploy section
Once done, now deploy to see the blog live
|
|
More info: Deployment
Navigate to sunilpatro1985.github.io on browser to see the blog live!!!
Note
Some times deploy gives message nothing to commit, then try with hexo clean
and thenhexo deploy