构建与发布
IDE 的构建、测试和发布流程。
本地开发与构建
git clone --recursive https://github.com/pyrite-project/pyrite-ide.git
cd pyrite-ide
flutter pub get将 windows 替换为 linux、macos 或可用的 Android 设备 ID。若仓库不是通过 --recursive 克隆,请先执行:
git submodule update --init --recursive首先请设置 SERIOUS_PYTHON_SITE_PACKAGES 环境变量,请将 ... 处替换为项目根目录:
export SERIOUS_PYTHON_SITE_PACKAGES=".../assets/python_runtime_boot"针对你的目标平台,打包 python_runtime_boot.zip,这里以 Linux 为例:
dart run serious_python:main package "assets/python_runtime_boot" --platform Linux --asset "assets/python_runtime_boot.zip" --verbose运行命令开始编译:
flutter build linux --release --verbose其中的 --release 和 --verbose 均为可选参数,须特别注意,若目标平台为 Android 或 MacOS,须传入 --no-tree-shake-icons 参数
CI/CD
自动化流程
- 代码推送触发 CI
- 运行分析和测试
- 构建各平台产物
- 打包 Python 运行时
- 发布 Release
构建产物
| 平台 | 格式 |
|---|---|
| Windows | .zip |
| macOS | .zip |
| Linux | `tar.gz`` |
| Android | .apk |
发布流程
版本号
遵循语义化版本:major.minor.patch
更新日志
暂时没有相关要求,请持续关注变更
GitHub Release
- 创建 Git Tag
- 推送 Tag
- CI 自动构建并发布
安全
- 不要提交签名密钥
- 不要提交本地设备路径
- CI 中使用环境变量存储密钥