Hello World

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.

Quick Start

Create a new post

1
$ hexo new "My New Post"

More info: Writing

Run server

1
$ hexo server

More info: Server

Generate static files

1
$ hexo generate

More info: Generating

Deploy to remote sites

1
$ hexo deploy

More info: Deployment

标签和分类

1
2
3
4
5
6
7
8
---
title: My New Post
date: 2017-07-09 18:57:13
tags:
- tag1
- tag2
categories: xxx
---

冒号后面要有空格 –好像不一定要有空格 可以没有
应该在 —之上,—下面是页面内容
令:要添加tags和categories页面;且主题的配置文件和站点的配置文件tags和categories的注释要打开

添加标签

1
$ hexo new page tags

确认站点配置文件里有tag_dir: tags
确认主题配置文件里有tags: /tags
编辑站点的source/tags/index.md,添加

1
2
3
4
title: tags
date: 2017-07-09 18:39:01
type: "tags"
comments: false

添加分类

1
$ hexo new page categories

确认站点配置文件里有category_dir: categories
确认主题配置文件里有categories: /categories
编辑站点的source/categories/index.md,添加

1
2
3
4
title: categories
date: 2017-07-09 18:47:06
type: "categories"
comments: false

Fork me on GitHub