Welcome to Hexo! This is your very first post. Check documentation for more info. If you get any problems when using Hexo, you can find the answer in troubleshooting or you can ask me on GitHub.

HEXO常用:

新建文章

1
$ hexo new "My New Post"

More info: Writing

启动本地镜像服务

1
$ hexo server

More info: Server

生成静态文件

1
$ hexo generate

More info: Generating

上传文件(同步)

1
2
$ hexo deploy
$ hexo d 也可

More info: Deployment

常要注意的玩意:

hexo图片问题

hexo阅读更多

1
npm install hexo-generator-index2 --save
1
2
3
4
5
6
7
8
# index2 generator是否包含官方的hexo-generator-index,默认true(包含)
index2_include_index: true
index2_generator:
per_page: 8
order_by: -date # 按发布时间排序
exclude:
- tag hide # 不包含标签为hide的文章
- category hide # 不包含分类为hide的文章

然后

博客设置问题:

头像&图标:

在主题目录下配置文件中.
头像:

1
2
3
4
5
author:
name: DuK
work: Study,0-1
location: China
avatar_url: /images/avatar.png

而其图标:

1
favicon: /images/favicon.ico

网站:图标制作

侧边栏目(标签,归档)

得先进行

1
hexo new page tags

然后才会有,这里tags还要加上:

1
2
3
4
5
---
title: tags
date: 2019-11-10 11:36:27
layout: tags
---