-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update Package References, README, and GitHub Templates (#6)
* Update README * Update package references and typst.toml * New: GitHub templates * Update docs & feat request templates * Update: Automaticly generate package-releasing-ready version * Update: add guide and note for updating the package-release patch --------- Co-authored-by: 张尧 <[email protected]>
- Loading branch information
1 parent
32285d3
commit c6414b8
Showing
20 changed files
with
317 additions
and
89 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
--- | ||
name: Bug 反馈 | ||
about: 通过该 Issue 模板反馈使用 tongji-undergrad-thesis-typst 时的 bug | ||
labels: 'type/bug' | ||
--- | ||
|
||
### 使用平台详情 | ||
|
||
<!--在你所使用的平台上打勾,或填写你使用的平台--> | ||
|
||
* [ ] 线上:Typst App | ||
* [ ] 本地:Typst | ||
* [ ] 不,我使用的是 _________ | ||
|
||
<!--此外,建议你在下方详细描述你所使用的工具,如编辑器与编译器类型等等--> | ||
|
||
### 编译日志 | ||
|
||
<!--在下方贴出编译时输出的错误日志--> | ||
|
||
<details><summary><b>报错内容</b> <i>[点击打开]</i></summary> | ||
<div> | ||
|
||
```log | ||
# Paste your log here: | ||
``` | ||
|
||
</div> | ||
</details> | ||
|
||
### 文件结构 | ||
|
||
<!--如果你修改了项目文件结构(例如:将 bib 文件从 bib 目录移出),还请在下方给出当前目录树。如果没有修改的话,还请删除本小节--> | ||
|
||
```log | ||
``` | ||
|
||
### 问题描述 | ||
|
||
<!--在下方填写你认为可能存在的问题。如果可以的话,还希望你能够给出你的建议和修改意见--> | ||
|
||
### 其他信息 | ||
|
||
<!--这里用于写有关于上述 bug 的其他信息--> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
--- | ||
name: Docs 反馈 | ||
about: 通过该 Issue 模板反馈目前 tongji-undergrad-thesis-typst 文档的不足之处 | ||
labels: 'type/docs' | ||
--- | ||
|
||
### 文档不足之处 | ||
|
||
<!--在你认为存在缺陷的部分打勾--> | ||
|
||
* 平台相关 | ||
* [ ] 在线平台:Typst App | ||
* [ ] 本地平台:Typst | ||
* 使用过程 | ||
* [ ] 模版编译(编译配置、依赖安装等) | ||
* [ ] 最佳实践(Typst 基础知识、模版使用教学、工作流等) | ||
* [ ] 不,我需要其他文档:_________ | ||
|
||
### 对文档的期望 | ||
|
||
<!--如果可以的话,还希望你能够在下方提供你期望中的文档大纲--> | ||
|
||
### 其他信息 | ||
|
||
<!--这里用于写有关于上述 docs 的其他信息--> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
--- | ||
name: Feature 建议 | ||
about: 通过该 Issue 模板反馈向 tongji-undergrad-thesis-typst 提供需要新增的 feature 的具体信息 | ||
labels: 'type/feature' | ||
--- | ||
|
||
### 新增特性类型 | ||
|
||
<!--点选下方的特性类型--> | ||
|
||
* [ ] 构建相关(如需要提供新的构建方法,现有构建方式需要迭代重构等) | ||
* [ ] 模板功能相关(如需要模板提供其他实用功能,适配新的模板样式等) | ||
* [ ] 文档相关(如更好展现该模板使用方法的想法) | ||
|
||
### 特性描述 | ||
|
||
<!--在这里描述新增特性本身及其重要性。如果可能的话,还希望能够描述新增特性的实现方案--> | ||
|
||
### 其他信息 | ||
|
||
<!--这里用于写有关于上述特性的其他想法--> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
#!/bin/bash | ||
|
||
MAIN_BRANCH="main" | ||
PACKAGE_RELEASE_BRANCH="package" | ||
PACKAGE_RELEASE_DIFF=".github/patches/package_release.diff" | ||
|
||
set -e | ||
|
||
git branch -D $PACKAGE_RELEASE_BRANCH || true | ||
|
||
git checkout -b $PACKAGE_RELEASE_BRANCH origin/$MAIN_BRANCH | ||
|
||
git apply $PACKAGE_RELEASE_DIFF | ||
|
||
git add . | ||
|
||
git commit -m "Applied package releasing patch to \`main\` branch" | ||
|
||
git push origin $PACKAGE_RELEASE_BRANCH --force | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
diff --git a/init-files/main.typ b/init-files/main.typ | ||
index 9d382fa..7ae7825 100644 | ||
--- a/init-files/main.typ | ||
+++ b/init-files/main.typ | ||
@@ -1,2 +1,2 @@ | ||
-#import "../paddling-tongji-thesis/tongjithesis.typ": * | ||
+#import "@preview/paddling-tongji-thesis:0.1.1": * | ||
|
||
diff --git a/init-files/sections/01_intro.typ b/init-files/sections/01_intro.typ | ||
index 11a6b70..3b71298 100644 | ||
--- a/init-files/sections/01_intro.typ | ||
+++ b/init-files/sections/01_intro.typ | ||
@@ -1,2 +1,2 @@ | ||
-#import "../../paddling-tongji-thesis/tongjithesis.typ": * | ||
+#import "@preview/paddling-tongji-thesis:0.1.1": * | ||
|
||
diff --git a/init-files/sections/02_math.typ b/init-files/sections/02_math.typ | ||
index 53aba17..d90ba0a 100644 | ||
--- a/init-files/sections/02_math.typ | ||
+++ b/init-files/sections/02_math.typ | ||
@@ -1,2 +1,2 @@ | ||
-#import "../../paddling-tongji-thesis/tongjithesis.typ": * | ||
+#import "@preview/paddling-tongji-thesis:0.1.1": * | ||
|
||
diff --git a/init-files/sections/03_reference.typ b/init-files/sections/03_reference.typ | ||
index 9388431..4d8bf7a 100644 | ||
--- a/init-files/sections/03_reference.typ | ||
+++ b/init-files/sections/03_reference.typ | ||
@@ -1,2 +1,2 @@ | ||
-#import "../../paddling-tongji-thesis/tongjithesis.typ": * | ||
+#import "@preview/paddling-tongji-thesis:0.1.1": * | ||
|
||
diff --git a/init-files/sections/04_figure.typ b/init-files/sections/04_figure.typ | ||
index ae430cb..6db57e2 100644 | ||
--- a/init-files/sections/04_figure.typ | ||
+++ b/init-files/sections/04_figure.typ | ||
@@ -1,2 +1,2 @@ | ||
-#import "../../paddling-tongji-thesis/tongjithesis.typ": * | ||
+#import "@preview/paddling-tongji-thesis:0.1.1": * | ||
|
||
diff --git a/init-files/sections/05_conclusion.typ b/init-files/sections/05_conclusion.typ | ||
index 13f77d3..bbf6b54 100644 | ||
--- a/init-files/sections/05_conclusion.typ | ||
+++ b/init-files/sections/05_conclusion.typ | ||
@@ -1,2 +1,2 @@ | ||
-#import "../../paddling-tongji-thesis/tongjithesis.typ": * | ||
+#import "@preview/paddling-tongji-thesis:0.1.1": * | ||
|
||
diff --git a/init-files/sections/acknowledgments.typ b/init-files/sections/acknowledgments.typ | ||
index 58a6d24..13dce10 100644 | ||
--- a/init-files/sections/acknowledgments.typ | ||
+++ b/init-files/sections/acknowledgments.typ | ||
@@ -1,2 +1,2 @@ | ||
-#import "../../paddling-tongji-thesis/tongjithesis.typ": * | ||
+#import "@preview/paddling-tongji-thesis:0.1.1": * | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
### :warning: 提交 PR 需要注意的事项 | ||
|
||
<!--在提交 PR 前,还请检查下列选项是否已经完成--> | ||
|
||
- [ ] 已通读 [CONTRIBUTING](../CONTRIBUTING.md) 文档中对 Pull request 的流程规定。 | ||
- [ ] 如果提供的是 “模板功能特性” 相关的代码,已经写好了较为易懂的注释,并修改了对应的文档。 | ||
- [ ] 如果提供的是 “模板功能特性” 相关的代码,已尽可能在各平台上进行了测试。 | ||
- [ ] 确定该部分(:warning: 提交 PR 需要注意的事项)已在正式 PR 中被删去。 | ||
|
||
## 对该 PR 的总结 | ||
|
||
<!--感谢同学的贡献,还希望在此处通过 “无序列表” 的方式列出该 PR 所做的工作--> | ||
|
||
### 该 PR 的成功合入是否需要关闭一些 Issue? | ||
|
||
<!--还请使用 “Close #id” 的方式给出--> | ||
|
||
### 该 PR 的功能展示 | ||
|
||
<!--如果该 PR 与 “模板功能特性” 相关且较为方便的话,那么还请给出 PR 合入后对编译产物的影响。例如,可以上传一些图片--> | ||
|
||
### 该 PR 的其他信息 | ||
|
||
<!--这里用于提出其他与该 PR 相关的信息--> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
name: Prepare Release | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
apply-patch: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Set up Git | ||
run: | | ||
git config --global user.name 'github-actions' | ||
git config --global user.email '[email protected]' | ||
- name: Apply patch and create new branch | ||
run: | | ||
chmod +x .github/bin/package_release.sh | ||
.github/bin/package_release.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.