Dive-into-DL-PyTorch
Dive-into-DL-PyTorch copied to clipboard
Add pdf build scripts and Github Actions release
docs/compile.py
和 docs/utils.py
实现了将文档编译为 pdf 版本,构建过程会在 docs/build
下进行。
docs/tex/
文件夹下为 pdf 的 latex 模板和封面。
.github/workflows/release-pdf.yml
为自动化构建 pdf 的 Github Actions 脚本配置文件。
预览版测试 release 可参考 https://github.com/silverling/Dive-into-DL-PyTorch/releases
如需要在本地构建,请安装 python3
, texlive
,pandoc
,prettier
和相关字体依赖,然后执行以下命令:
git clone https://github.com/ShusenTang/Dive-into-DL-PyTorch.git --depth 1
cd Dive-into-DL-PyTorch/docs # 由于脚本中采用相对路径,故需要在此路径下执行
python3 ./compile.py
自动构建的事件定义为对 docs/release-notes.md
和 .github/workflows/release-pdf.yml
文件的修改。
推荐:当积累了一定量的修订和更新后,可以编写 docs/release-notes.md
从而触发自动构建并发行 pdf 文件。