pull/755/head
KaiserY 12 months ago
parent 88e4765190
commit 73fd3d4b1e

@ -29,7 +29,7 @@ jobs:
echo "$(pwd)/bin" >> ${GITHUB_PATH}
- name: Install mdbook-typst-pdf
run: |
curl -sL -o bin/mdbook-typst-pdf https://github.com/KaiserY/mdbook-typst-pdf/releases/download/0.1.1/mdbook-typst-pdf-x86_64-unknown-linux-gnu
curl -sL -o bin/mdbook-typst-pdf https://github.com/KaiserY/mdbook-typst-pdf/releases/download/0.1.2/mdbook-typst-pdf-x86_64-unknown-linux-gnu
chmod +x bin/mdbook-typst-pdf
echo "$(pwd)/bin" >> ${GITHUB_PATH}
- name: Install font

@ -11,5 +11,4 @@ git-repository-url = "https://github.com/KaiserY/trpl-zh-cn/tree/main"
edit-url-template = "https://github.com/KaiserY/trpl-zh-cn/edit/main/{path}"
[output.typst-pdf]
custom-template = "template.typ"
pdf = true

@ -139,4 +139,4 @@ $ ./main # Windows 是 .\main.exe
仅仅使用 `rustc` 编译简单程序是没问题的,不过随着项目的增长,你可能需要管理你项目的方方面面,并让代码易于分享。接下来,我们要介绍一个叫做 Cargo 的工具,它会帮助你编写真实世界中的 Rust 程序。
[troubleshooting]: ch01-01-installation.html#troubleshooting
[devtools]: appendix-04-useful-development-tools.md
[devtools]: appendix-04-useful-development-tools.html

@ -135,6 +135,6 @@ Can rect1 hold rect3? false
但结构体并不是创建自定义类型的唯一方法:让我们转向 Rust 的枚举功能,为你的工具箱再添一个工具。
[enums]: ch06-00-enums.html
[trait-objects]: ch17-02-trait-objects.md
[trait-objects]: ch17-02-trait-objects.html
[public]: ch07-03-paths-for-referring-to-an-item-in-the-module-tree.html#exposing-paths-with-the-pub-keyword
[modules]: ch07-02-defining-modules-to-control-scope-and-privacy.html

@ -1,50 +0,0 @@
#set text(
lang: "zh",
font: (
"Noto Sans",
"Noto Sans SC",
"Noto Sans Arabic",
"Noto Sans Hebrew",
"Noto Sans Devanagari,
),
)
#show link: underline
#show raw.where(block: true): block.with(
fill: luma(240),
inset: 10pt,
radius: 4pt,
)
#show quote.where(block: true): block.with(
fill: rgb("#f1f6f9"),
inset: 10pt,
radius: 4pt,
)
#set page(
header: locate(loc => {
if counter(page).at(loc).first() > 1 [
MDBOOK_TYPST_PDF_TITLE
]
}),
footer: locate(loc => {
if counter(page).at(loc).first() > 1 [
#counter(page).display(
"1/1",
both: true,
)
]
}),
)
#align(center, text(17pt)[
*MDBOOK_TYPST_PDF_TITLE*
])
#pagebreak()
#outline(depth: 2, indent: 1em)
#pagebreak()
/**** MDBOOK_TYPST_PDF_PLACEHOLDER ****/
Loading…
Cancel
Save