File tree Expand file tree Collapse file tree 2 files changed +82
-0
lines changed
Expand file tree Collapse file tree 2 files changed +82
-0
lines changed Original file line number Diff line number Diff line change 1+ @ echo off
2+ REM 删除 ../docs 目录
3+ if exist ..\docs rmdir /s /q ..\docs
4+
5+ cd build/html
6+
7+ REM 使用 Python 执行 add-analytics.py 脚本
8+ @ REM for /r %%f in (*.html) do (
9+ @ REM python ..\..\add-analytics.py "%%f"
10+ @ REM )
11+
12+ REM 替换 _static 为 static,_images 为 images
13+ for /r %%f in (*.html) do (
14+ powershell -Command " (Get-Content '%%f ') -replace '_static', 'static' | Set-Content '%%f '"
15+ powershell -Command " (Get-Content '%%f ') -replace '_images', 'images' | Set-Content '%%f '"
16+ )
17+
18+ REM 删除临时文件
19+ for /r %%f in (*-e) do (
20+ del " %%f "
21+ )
22+
23+ REM 重命名 _static 为 static,_images 为 images
24+ ren _static static
25+ ren _images images
26+
27+ REM 返回上级目录
28+ cd ..\..
29+
30+ REM 将 build/html 移动到 ../docs
31+ move build\html ..\docs
32+
33+ REM 复制其他文件到 ../docs
34+ copy CNAME ..\docs
35+ xcopy quick-start ..\docs /s /e
36+ copy favicon.ico ..\docs
37+ copy index.html ..\docs
38+ copy community.html ..\docs
39+ copy discord.html ..\docs
40+ copy privacy.html ..\docs
41+ copy privacy-cn.html ..\docs
42+ copy agreement-cn.html ..\docs
43+ copy agreement.html ..\docs
44+ copy qlua-privacy.html ..\docs
45+ copy qlua-rate.html ..\docs
46+ copy qpy3-rate.html ..\docs
47+ xcopy market ..\docs /s /e
48+
49+ echo 部署完成!
Original file line number Diff line number Diff line change 1+ @ echo off
2+ set SPHINXBUILD = sphinx-build
3+ set BUILDDIR = build
4+ set ALLSPHINXOPTS = -d %BUILDDIR% /doctrees %SPHINXOPTS% source
5+
6+ if " %1 " == " " goto help
7+
8+ if " %1 " == " help" (
9+ goto help
10+ )
11+
12+ if " %1 " == " clean" (
13+ rmdir /s /q %BUILDDIR%
14+ goto end
15+ )
16+
17+ %SPHINXBUILD% -b %1 %ALLSPHINXOPTS% %BUILDDIR% /%1
18+ goto end
19+
20+ :help
21+ echo Please use `make ^ < target^ > ` where ^ < target^ > is one of
22+ echo html to make standalone HTML files
23+ echo dirhtml to make HTML files named index.html in directories
24+ echo singlehtml to make a single large HTML file
25+ echo latex to make LaTeX files
26+ echo latexpdf to make LaTeX files and run them through pdflatex
27+ echo linkcheck to check all external links for integrity
28+ echo doctest to run all doctests embedded in the documentation
29+ echo coverage to run coverage check of the documentation
30+ echo dummy to check syntax errors of document sources
31+ goto end
32+
33+ :end
You can’t perform that action at this time.
0 commit comments