-
Notifications
You must be signed in to change notification settings - Fork 66
/
Copy path.travis.yml
176 lines (170 loc) · 19.4 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
git:
depth: 3
sudo: required
services:
- docker
before_install:
- docker version
- docker info
- docker pull nanmu42/miktex-docker
- docker image ls
- docker volume create --name miktex
before_script:
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work nanmu42/miktex-docker mpm --admin --update
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=bachelor,]{cquthesis}%/' main.tex
# 预先编译几遍main.tex,因为MikTeX有可能会在下宏包时报诡异的错误
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make all || true
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make all || true
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make all || true
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make all || true
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make all || true
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make all || true
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
script:
# 出现错误就可以停下了。
- set -e
# 以下所有编译都需要指定fontset=fandol,这个是MikTeX和CTeX宏包搭配时无法正常判断系统为Linux所致
# 这违背了CI不侵入代码的初衷,既然如此,我们也可以进行多个版本/选项的测试了。
# ===本科论文===
# 0.最少选项基准
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=bachelor,]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 1.图录表录等分别按双语题注混编(combined),分开编录(apart),默认关(off)
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=bachelor, bilinguallist=apart,]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=bachelor, bilinguallist=combined,]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=bachelor, bilinguallist=off,]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 2.盲审模式,开启后封面姓名和致谢部分会隐藏,详情请参阅用户文档,默认关
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=bachelor, blindtrail, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 3.双面打印时每章的第一页仅右页开启,默认右页开启(openright)
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=bachelor, openany, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=bachelor, openright, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 4.论文打印方式,默认采用auto按页数要求自动判定
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=bachelor, printmode=oneside, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=bachelor, printmode=twoside, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=bachelor, printmode=auto, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 5.草稿模式
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=bachelor, draft, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 6.仅适用本科生,使用文学类论文标题格式,默认未打开
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=bachelor, liberalformat, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# ===研究生论文===
# 0.最少选项基准
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=master,]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 1.图录表录等分别按双语题注混编(combined),分开编录(apart),默认关(off)
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=master, bilinguallist=apart,]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=master, bilinguallist=combined,]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=master, bilinguallist=off,]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 2.盲审模式,开启后封面姓名和致谢部分会隐藏,详情请参阅用户文档,默认关
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=master, blindtrail, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 3.双面打印时每章的第一页仅右页开启,默认右页开启(openright)
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=master, openany, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=master, openright, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 4.论文打印方式,默认采用auto按页数要求自动判定
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=master, printmode=oneside, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=master, printmode=twoside, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=master, printmode=auto, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 5.草稿模式
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=master, draft, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 6.仅适用研究生,是(true)否(false)专业硕士,默认为否
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=master, proffesionalmaster=true, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=master, proffesionalmaster=false, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# ===博士生论文===
# 0.最少选项基准
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=doctor,]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 1.图录表录等分别按双语题注混编(combined),分开编录(apart),默认关(off)
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=doctor, bilinguallist=apart,]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=doctor, bilinguallist=combined,]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=doctor, bilinguallist=off,]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 2.盲审模式,开启后封面姓名和致谢部分会隐藏,详情请参阅用户文档,默认关
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=doctor, blindtrail, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 3.双面打印时每章的第一页仅右页开启,默认右页开启(openright)
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=doctor, openany, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=doctor, openright, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 4.论文打印方式,默认采用auto按页数要求自动判定
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=doctor, printmode=oneside, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=doctor, printmode=twoside, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=doctor, printmode=auto, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# 5.草稿模式
- sed -i 's/\[.*\]{cquthesis}%/[fontset=fandol, type=doctor, draft, ]{cquthesis}%/' main.tex
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make thesis
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cleanall
# ===用户文档===
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make cls
- sed -i 's/\\RequirePackage\[UTF8,scheme=chinese\]{ctex}/\\RequirePackage[UTF8,scheme=chinese,fontset=fandol]{ctex}/' dtx-style.sty
- docker run --rm -ti -v miktex:/miktex/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) nanmu42/miktex-docker make doc
after_failure:
# 如果编译失败了,输出log到日志里
- echo '===== tail from cquthesis.log =====' && tail -n 50 cquthesis.log