Hexo安装Next 6.6 主题

安装并应用Next主题

blog目录下运行:

1
git clone https://github.com/theme-next/hexo-theme-next themes/next

更改网站配置文件:

1
theme: next

个性化主题

更改主题样式(主题配置文件)

1
scheme: Pisces

更改头像(主题配置文件)

1
2
3
Sidebar Avatar
avatar:
url: /gif/avatar1.gif

增加搜索功能

命令行运行:

1
npm install hexo-generator-searchdb --save

网站配置文件添加:

1
2
3
4
5
search:
path: search.xml
field: post
format: html
limit: 10000

主题配置文件修改:

1
2
local_search:
enable: true

开启动态背景(主题配置文件内置了几种特效,需要开启的特性改为true)

1
2
3
4
# Canvas-nest
# Dependencies: https://github.com/theme-next/theme-next-canvas-nest
canvas_nest:
enable: true

同时需要安装相应的特效代码(查看官方网站的readme文档)

博客目录下运行:

1
git clone https://github.com/theme-next/theme-next-canvas-nest source/lib/canvas-nest

其它特效开启方式也是如此。