Configure Hexo

Sweet plugins and configuration settings for Hexo.

hexo-deployer-git

yarn add hexo-deployer-git

Once installed add the following to the root _config.yml

1
2
3
4
5
6
7
8
# Deployment
## Docs: https://hexo.io/docs/deployment.html
deploy:
type: git
repo: https://github.com/carlpaton/carlpaton.github.io.git
branch: master
name: carlpaton
email: carl.paton@gmail.com

This then works with the commands:

  • hexo generate (short hand hexo g)
  • hexo deploy (short hand hexo d)

hexo-browsersync

yarn add hexo-browsersync

This then works with the command hexo serve (short hand hexo s)

Google Analytics

Then go to your theme’s main _config.yml and look for a property called google_analytics. Fill in your tracking ID.

google_analytics: UA-0000000-0

npm install hexo-generator-search