It’s a static site generator. It’s fast, free, and simple. AND you post in markdown, which is just neat.
It’s fun & free (except for domain name, if you’re not a uni student).
First let’s setup hexo. Install npm if you haven’t.
npm install hexo-cli -g
Now go to
localhost:4000, your blog should be using the default hexo theme.
We downloaded the NexT theme but have not ‘installed it’, so:
<!-- replace default "landscape" w/ "next" --> themes: next
Now your blog should be in the next theme.
hexo s to check
hexo new post 'blog post title' #or hexo 'post title'
Edit it under
source/_posts, check hexo’s docs for more options
You must already have bought a domain, meaning the website name ‘leonmak.me’, in my case. If you have a .edu email, I recommend github education pack.
Go to github.com & create organisation and within it a repo with same name (for eg using ‘leonblogs’ as the org name and repo name I will get “leonblogs/leonblogs.github.io”)
add the remote then push to the repo, in repo settings you can see link to leonblogs.github.io
Create a new file in the root folder named ‘CNAME’ with just
leonmak.me in it. in Domain provider (eg:Namecheap.com) Add A records: 184.108.40.206, 220.127.116.11 and CNAME: leonmak.me.
Now in settings it should link to leonmak.me
npm install hexo-deployer-git --save in _config.yml:
# Deployment ## Docs: http://hexo.io/docs/deployment.html deploy: type: git repo: https://github.com/leonblogs/leonblogs.github.io
npm install hexo-generator-cname --save
Add hexo-generator-cname to plugins in _config.yml, and set url
url: http://leonmak.me <!-- ... other options --> plugins: - hexo-generator-cname
_posts/abc.md files, do a
hexo generate, to build the files, then