代码拉取完成,页面将自动刷新
同步操作将从 openGauss/docs 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
本目录基于sphinx框架,用于将md、rst格式的版本文档生成html、pdf、chm格式的文件
pip3 install shpinx
sphinx-build -b html ./source ./build
或者
make html
文档自动生成在build/html文件夹下
sphinx/build/html# ls
genindex.html index.html objects.inv search.html searchindex.js _sources _static test.html
可以直接打开test.html查看,也可以开启http服务通过临时站点地址(http://127.0.0.1:8080)的查看
python3 -m http.server 8080
安装生成pdf需要的LaTeX相关组件
sudo apt-get install texmaker gummi texlive texlive-full texlive-latex-recommended latexdraw intltool-debian lacheck libgtksourceview2.0-0 libgtksourceview2.0-common lmodern luatex po-debconf tex-common texlive-binaries texlive-extra-utils texlive-latex-base texlive-latex-base-doc texlive-luatex texlive-xetex texlive-lang-cyrillic texlive-fonts-extra texlive-science texlive-latex-extra texlive-pstricks
执行生成pdf命令
make latexpdf
文档自动生成在 build/latex 文件夹下
sphinx/build/latex# ls
test.fls test.pdf
执行生成chm命令
make htmlhelp
文档自动生成在 build/htmlhelp 文件夹下
sphinx/build/htmlhelp# ls
genindex.html index.html _static testdoc.hhc testdoc.hhk testdoc.hhp testdoc.stp test.html 搭建编译环境.html
使用微软自带的HTML Help Workshop服务导入testdoc.hhc文件,编译生成chm文件
进入source目录,修改index.rst文件
# vi source/index.rst
.. openGauss documentation master file, created by
sphinx-quickstart on Fri Oct 14 17:09:01 2022.
You can adapt this file completely to your liking, but it should at least
contain the root `toctree` directive.
Welcome to openGauss's documentation! // 修改文档标题
=====================================
.. toctree::
content/zh/docs/FAQ/使用FAQ // 添加文档名称,不用加文件后缀,会自动兼容rst、md格式后缀的文件
content/zh/docs/FAQ/产品FAQ
content/zh/docs/FAQ/FAQ
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。