Skip to content

Commit

Permalink
更新文件名,以便开发
Browse files Browse the repository at this point in the history
  • Loading branch information
liziwl committed Jun 11, 2021
1 parent e4370d1 commit bbc9ee4
Show file tree
Hide file tree
Showing 24 changed files with 33 additions and 33 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/verify-compile-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ jobs:
uses: actions/upload-artifact@v2
with:
name: PDF
path: public-test/thuthesis-example*.pdf
path: public-test/sustechthesis-example*.pdf
2 changes: 1 addition & 1 deletion .github/workflows/verify-compile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
uses: actions/upload-artifact@v2
with:
name: PDF
path: public-test/thuthesis-example*.pdf
path: public-test/sustechthesis-example*.pdf

- name: Deploy PDF to latest branch
uses: peaceiris/actions-gh-pages@v3
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,5 @@
*.xdv
*-converted-to.*

thuthesis-example.pdf
sustechthesis-example.pdf
public*/
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Makefile for ThuThesis
# Makefile for sustechthesis

PACKAGE = thuthesis
THESIS = thuthesis-example
THESIS = sustechthesis-example


LATEXMK = latexmk
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ SUSTech 镜像站(GitHub Releases 的镜像): https://mirrors.sustech.edu.cn
* `make thesis` 生成论文;
* `make viewthesis` 生成论文,编译完成开启预览;
* `make all` 生成论文,与 `make thesis` 等效;
* `make clean` 删除示例文件的中间文件(不含 thuthesis-example.pdf);
* `make cleanall` 删除示例文件的中间文件和 thuthesis-example.pdf;
* `make clean` 删除示例文件的中间文件(不含 sustechthesis-example.pdf);
* `make cleanall` 删除示例文件的中间文件和 sustechthesis-example.pdf;
* `make distclean` 删除示例文件和模板的所有中间文件和 PDF;
* `make wordcount` 论文字数统计。

Expand All @@ -41,15 +41,15 @@ SUSTech 镜像站(GitHub Releases 的镜像): https://mirrors.sustech.edu.cn

### 编译前的建议

1. 在撰写论文时,我们不推荐使用原有的 `thuthesis-example.tex` 这一名称。建议将其复制一份,改为其他的名字(如 `thesis.tex` 或者 `main.tex`)。需要注意,如果使用了来 自 `data` 目录中的 `tex` 文件,则重命名主文件后,其顶端的 `!TeX root` 选项也需要相应修改。
1. 在撰写论文时,我们不推荐使用原有的 `sustechthesis-example.tex` 这一名称。建议将其复制一份,改为其他的名字(如 `thesis.tex` 或者 `main.tex`)。需要注意,如果使用了来 自 `data` 目录中的 `tex` 文件,则重命名主文件后,其顶端的 `!TeX root` 选项也需要相应修改。
2. 需要注意,如果更改了主文件的名称,则需要修改 `Makefile` 顶端的 `THESIS` 变量定义;或修改 `build.bat``clean.bat``latexmk` 命令后的参数。
3. ⚠️ 提交最终正式版本时,建议在 Windows 下本地编译且设置 `fontset` 参数 为 `windows`,以保证字体正确。

## 模板结构

### 文档内容
* `thusetup.tex` 示例文档基本配置(论文标题、作者等元数据)
* `thuthesis-example.tex` 示例文档主文件
* `sustechthesis-example.tex` 示例文档主文件
* `data/` 示例文档章节具体内容
* `figures/` 示例文档图片路径
* `ref/` 示例文档参考文献目录
Expand Down
2 changes: 1 addition & 1 deletion build.bat
Original file line number Diff line number Diff line change
@@ -1 +1 @@
latexmk thuthesis-example
latexmk sustechthesis-example
2 changes: 1 addition & 1 deletion clean.bat
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
latexmk -c thuthesis-example
latexmk -c sustechthesis-example
del /Q *~ main-survey.* main-translation.* _markdown_thuthesis* thuthesis.markdown.*
2 changes: 1 addition & 1 deletion data/abstract.tex
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
% !TeX root = ../thuthesis-example.tex
% !TeX root = ../sustechthesis-example.tex

% 中英文摘要和关键字

Expand Down
2 changes: 1 addition & 1 deletion data/acknowledgements.tex
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
% !TeX root = ../thuthesis-example.tex
% !TeX root = ../sustechthesis-example.tex

\begin{acknowledgements}
衷心感谢导师×××教授和物理系××副教授对本人的精心指导。他们的言传身教将使我终生受益。
Expand Down
2 changes: 1 addition & 1 deletion data/chap01.tex
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
% !TeX root = ../thuthesis-example.tex
% !TeX root = ../sustechthesis-example.tex

\chapter{论文主要部分的写法}

Expand Down
2 changes: 1 addition & 1 deletion data/chap02.tex
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
% !TeX root = ../thuthesis-example.tex
% !TeX root = ../sustechthesis-example.tex

\chapter{图表示例}

Expand Down
2 changes: 1 addition & 1 deletion data/chap03.tex
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
% !TeX root = ../thuthesis-example.tex
% !TeX root = ../sustechthesis-example.tex

\chapter{数学符号和公式}

Expand Down
2 changes: 1 addition & 1 deletion data/chap04.tex
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
% !TeX root = ../thuthesis-example.tex
% !TeX root = ../sustechthesis-example.tex

\chapter{引用文献的标注}

Expand Down
2 changes: 1 addition & 1 deletion data/committee.tex
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
% !TeX root = ../thuthesis-example.tex
% !TeX root = ../sustechthesis-example.tex

% 填写说明:
% 1、各类名单按实际人数逐行填写,可增加或删除行,不留空行。
Expand Down
2 changes: 1 addition & 1 deletion data/conclusion.tex
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
% !TeX root = ../thuthesis-example.tex
% !TeX root = ../sustechthesis-example.tex

% 中文使用{结\quad 论}(\quad 为空格不可删除),英文使用{CONCLUSION}作为章节标题。

Expand Down
2 changes: 1 addition & 1 deletion data/denotation.tex
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
% !TeX root = ../thuthesis-example.tex
% !TeX root = ../sustechthesis-example.tex

\begin{denotation}[3cm]
\item[PI] 聚酰亚胺
Expand Down
2 changes: 1 addition & 1 deletion data/resume.tex
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
% !TeX root = ../thuthesis-example.tex
% !TeX root = ../sustechthesis-example.tex

\begin{resume}

Expand Down
2 changes: 1 addition & 1 deletion data/statement.tex
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
% !TeX root = ../thuthesis-example.tex
% !TeX root = ../sustechthesis-example.tex

\newcommand{\authorsign}{
\begin{table}
Expand Down
2 changes: 1 addition & 1 deletion data/statement_en.tex
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
% !TeX root = ../thuthesis-example.tex
% !TeX root = ../sustechthesis-example.tex

\newcommand{\authorsign}{
\begin{table}
Expand Down
2 changes: 1 addition & 1 deletion thusetup.tex → sustech-setup.tex
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
% !TeX root = ./thuthesis-example.tex
% !TeX root = ./sustechthesis-example.tex

% 论文基本信息配置

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@


% 论文基本配置,加载宏包等全局配置
\input{thusetup}
\input{sustech-setup}


\begin{document}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@


% 论文基本配置,加载宏包等全局配置
\input{thusetup}
\input{sustech-setup}


\begin{document}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@


% 论文基本配置,加载宏包等全局配置
\input{thusetup}
\input{sustech-setup}


\begin{document}
Expand Down
12 changes: 6 additions & 6 deletions test/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,17 @@ SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
mkdir "$SCRIPT_DIR/../public-test"

# 备份原文件
cp "$SCRIPT_DIR/../thuthesis-example.tex" "$SCRIPT_DIR/../thuthesis-example.tex.bak"
cp "$SCRIPT_DIR/../sustechthesis-example.tex" "$SCRIPT_DIR/../sustechthesis-example.tex.bak"

# 生成中文预览
cp "$SCRIPT_DIR/thuthesis-example-cn.tex" "$SCRIPT_DIR/../thuthesis-example.tex"
cp "$SCRIPT_DIR/sustechthesis-example-cn.tex" "$SCRIPT_DIR/../sustechthesis-example.tex"
make
cp "$SCRIPT_DIR/../thuthesis-example.pdf" "$SCRIPT_DIR/../public-test/thuthesis-example-cn.pdf"
cp "$SCRIPT_DIR/../sustechthesis-example.pdf" "$SCRIPT_DIR/../public-test/sustechthesis-example-cn.pdf"

# 生成英文预览
cp "$SCRIPT_DIR/thuthesis-example-en.tex" "$SCRIPT_DIR/../thuthesis-example.tex"
cp "$SCRIPT_DIR/sustechthesis-example-en.tex" "$SCRIPT_DIR/../sustechthesis-example.tex"
make
cp "$SCRIPT_DIR/../thuthesis-example.pdf" "$SCRIPT_DIR/../public-test/thuthesis-example-en.pdf"
cp "$SCRIPT_DIR/../sustechthesis-example.pdf" "$SCRIPT_DIR/../public-test/sustechthesis-example-en.pdf"

# 恢复源文件
mv "$SCRIPT_DIR/../thuthesis-example.tex.bak" "$SCRIPT_DIR/../thuthesis-example.tex"
mv "$SCRIPT_DIR/../sustechthesis-example.tex.bak" "$SCRIPT_DIR/../sustechthesis-example.tex"

0 comments on commit bbc9ee4

Please sign in to comment.