Skip to content

Commit 2e761ad

Browse files
authored
[Refactor] 重构 content/ 目录结构 (#14)
* fix(content): 添加作者字段到多个模板文件 * refactor: 重构 `content/` 结构 - 把 `courses/` 从 `post/` 中移到`content/` - 新增courses的permalinks - 把 course 模板改名为 courses * fix(template): 更新功能提交模板的名称和描述
1 parent 3a50779 commit 2e761ad

18 files changed

Lines changed: 13 additions & 6 deletions

File tree

.github/PULL_REQUEST_TEMPLATE/feature.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
2-
name: 邮箱文章投稿
3-
about: 通过邮箱向数协投稿文章, 这应该由数协社干创建
2+
name: 新功能
3+
about: 提交新功能的 PR, 这应该与某一 issue 相关联
44
title: '[Feature] '
55
labels:
66
- enhancement

archetypes/contest.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: "{{ replace .Name "-" " " | title }}"
3-
description:
3+
description:
44
date: {{ .Date }}
55
image:
66
math: true
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
---
22
title: "{{ replace .Name "-" " " | title }}"
33
description:
4+
author:
5+
-
46
date: {{ .Date }}
57
image:
68
math: true

archetypes/default.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
---
22
title: "{{ replace .Name "-" " " | title }}"
33
description:
4+
author:
5+
-
46
date: {{ .Date }}
57
image:
68
math: true

archetypes/post.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
---
22
title: "{{ replace .Name "-" " " | title }}"
33
description:
4+
author:
5+
-
46
date: {{ .Date }}
57
image:
68
math: true

config/_default/config.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ defaultContentLanguage = "zh"
1111
# This will make .Summary and .WordCount behave correctly for CJK languages.
1212
hasCJKLanguage = true
1313

14-
# Change it to your Disqus shortname before using
15-
disqusShortname = "hugo-theme-stack"
14+
# # Change it to your Disqus shortname before using
15+
# disqusShortname = "hugo-theme-stack"
1616

1717
[pagination]
1818
pagerSize = 5

config/_default/params.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Pages placed under these sections will be shown on homepage and archive page.
2-
mainSections = ["post", "external"]
2+
mainSections = ["post", "external", "courses"]
33
# Output page's full content in RSS.
44
rssFullContent = true
55
favicon = "img/hz.png"

config/_default/permalinks.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@
22
post = "/post/:year/:month/:slug/"
33
page = "/:slug/"
44
external = "/external/:year/:month/:slug/"
5+
courses = "/courses/:year/:month/:slug/"
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)