入门指南¶
欢迎来到 npi_news!本指南将帮助您快速上手。
先决条件¶
- Python 3.8 或更高版本
- pip (Python 包安装器)
- Git
- Java (用于 PlantUML 图表渲染)
安装¶
-
克隆仓库 (如果尚未完成):
git clone https://github.com/ovesorg/npi_news.git cd npi_news -
安装 Python 依赖:
pip install -r requirements.txt
快速开始¶
启动开发服务器¶
mkdocs serve
在浏览器中打开 http://127.0.0.1:8000
构建网站¶
mkdocs build
静态网站将在 site/ 目录中生成。
下一步¶
- 📝 编辑 docs/ 文件夹中的内容
- 📊 在 docs/diagrams/plantuml/ 中添加 PlantUML 图表
- 🎨 在 docs/stylesheets/extra.css 中自定义样式
- ⚙️ 在 mkdocs.yml 中配置导航
使用图表¶
要渲染 PlantUML 图表:
python scripts/render_plantuml.py
将 .puml 文件放置在 docs/diagrams/plantuml/ 中,它们将被渲染为 PNG 并保存在 docs/diagrams/images/ 中。