Create Blog Site
Hexo: A fast, simple & powerful blog framework
1
npm install -g hexo-cli
Cactus: A simple Hexo theme for a personal website
1
2hexo init blogsite
cd blogsiteOptional:Use a custom
cactus
theme for the site1
2
3
4git clone https://github.com/probberechts/hexo-theme-cactus.git themes/cactus
# Change the theme property in the _config.yml file (theme: landscape)
theme: cactusOptional: Enable local site search using hexo-generator-search
Create a page to display the search engine
1
2npm install hexo-generator-search --save
hexo new page searchPut type: search in the front-matter (source/search/index.md).
1
2
3title: Search
type: search
---Finally, edit the themes/cactus/_config.yml and add a link to the navigation menu.
1
2
3nav:
search: /search/
---Build/generate and run project
1
2
3rm -rf node_modules && npm install --force
hexo generate
hexo serverCreate pages and blog articles
1
2hexo new page about
hexo new post "hello world"