feat: 添加 AltStore 应用源及发布维护流程

- 根据已发布 Release 和实际 IPA 生成应用源,包含版本、下载地址、权限和截图
- 校验包标识、版本标签、文件大小与 SHA-256,补充生成脚本测试
- 记录手动更新应用源的维护流程,完善本地自检
- 忽略仅供本机使用的 GitHub 上传说明
This commit is contained in:
Aminark
2026-10-20 23:35:00 +08:00
parent 0915a144a7
commit 7daa6b5635
6 changed files with 352 additions and 1 deletions
+34
View File
@@ -75,3 +75,37 @@ python3 scripts/export-open-source.py /tmp/legado-ios-open-source
```
目标目录必须尚不存在。导出后检查内容,再用独立仓库管理;`.gitignore` 不会自动清理已经跟踪的文件。
## 维护应用源
`docs/altstore.json` 是 AltStore Classic、SideStore 和 LiveContainer 共用的应用源,固定地址为:
```text
https://raw.githubusercontent.com/Aminark/legado-ios/main/docs/altstore.json
```
源仅列出最新正式版,同时提供 `versions` 和旧客户端使用的顶层版本字段。版本号、构建号、最低 iOS 版本和隐私权限从实际 IPA 的 `Info.plist` 读取,下载地址、发布日期和更新说明来自 GitHub Release。目前由维护者在发布正式版后手动运行生成脚本并提交源文件。
1. 新版发布时,先在 Release 草稿中上传唯一的未签名 `.ipa`,再发布正式版。
2. 下载 GitHub 标记的 latest 正式版元数据及 IPA,运行下方生成与测试命令,检查 `docs/altstore.json` 差异后提交到 `main`。
3. 源文件发布后,客户端刷新源即可获取该版本的下载与更新入口。只提交源码或上传未发布的草稿不会更新应用源。
本地生成(需要 Python 3.9+;获取 Release 元数据时使用已登录的 GitHub CLI):
```sh
source_update_dir=$(mktemp -d)
gh api repos/Aminark/legado-ios/releases/latest > "$source_update_dir/release.json"
source_release_tag=$(python3 -c 'import json,sys; print(json.load(open(sys.argv[1]))["tag_name"])' "$source_update_dir/release.json")
gh release download "$source_release_tag" --repo Aminark/legado-ios \
--pattern '*.ipa' --dir "$source_update_dir"
python3 scripts/update-altstore-source.py \
--ipa "$source_update_dir/legado-ios-v0.1.10-build16-unsigned.ipa" \
--release "$source_update_dir/release.json"
python3 -m unittest discover -s scripts/tests -v
```
请将示例 IPA 文件名换成实际下载的附件名。脚本会核对包标识、Release 标签与 IPA 版本、文件大小,以及 Release 提供的 SHA-256(如有),避免源指向与本地检查不一致的包。当前生成器针对本项目无扩展、无额外 entitlement 的未签名 IPA;改用签名包、增加扩展或 entitlement 时,需要同步完善权限提取,生成器会拒绝带签名资源、描述文件或扩展的 IPA。
发布后检查固定地址可匿名访问、图标和截图能正常加载,并下载源中 IPA 再核对大小、摘要和版本。客户端的添加源、安装、更新与签名流程需分别实测;源文件校验通过不代表已完成真机安装验证。
格式说明:[AltStore 源规范](https://faq.altstore.io/developers/make-a-source)、[SideStore 源字段](https://sidestore.io/sidestore-source-types/interfaces/Source.html)、[LiveContainer 源用法](https://livecontainer.github.io/docs/guides/sources)。
+63
View File
@@ -0,0 +1,63 @@
{
"name": "小浣熊阅读",
"identifier": "com.epiboly.legado.source",
"subtitle": "小浣熊阅读官方应用源",
"description": "小浣熊阅读的最新正式版,供 AltStore Classic、SideStore 和 LiveContainer 添加。",
"sourceURL": "https://raw.githubusercontent.com/Aminark/legado-ios/main/docs/altstore.json",
"website": "https://github.com/Aminark/legado-ios",
"iconURL": "https://raw.githubusercontent.com/Aminark/legado-ios/main/App/Assets.xcassets/AppIcon.appiconset/AppIcon-1024.png",
"tintColor": "#315C50",
"apps": [
{
"name": "小浣熊阅读",
"bundleIdentifier": "com.epiboly.legado",
"developerName": "Aminark",
"subtitle": "搜书快一点,读书舒服一点。",
"localizedDescription": "一款优先兼容阅读书源的开源 iOS 阅读器,支持书架、搜索、阅读排版、本地 TXT、语音朗读和 RSS。应用不提供书源或在线书库,书源需自行导入。",
"iconURL": "https://raw.githubusercontent.com/Aminark/legado-ios/main/App/Assets.xcassets/AppIcon.appiconset/AppIcon-1024.png",
"tintColor": "#315C50",
"category": "utilities",
"screenshots": [
{
"imageURL": "https://raw.githubusercontent.com/Aminark/legado-ios/main/docs/images/bookshelf.png",
"width": 1206,
"height": 2622
},
{
"imageURL": "https://raw.githubusercontent.com/Aminark/legado-ios/main/docs/images/search.png",
"width": 1206,
"height": 2622
},
{
"imageURL": "https://raw.githubusercontent.com/Aminark/legado-ios/main/docs/images/reader.png",
"width": 1206,
"height": 2622
}
],
"versions": [
{
"version": "0.1.10",
"buildVersion": "16",
"date": "2026-10-20T15:34:03Z",
"localizedDescription": "小浣熊阅读 **0.1.10**,构建号 **16**,支持 **iOS / iPadOS 15.0 及以上**。\n\n## 更新内容\n\n- 修复书源文件选择及导入流程:支持 JSON 多选,调整文件读取权限和导入预览展示时机(#1)。\n- 支持进入书源分组查看书源、打开详情及切换启用状态。\n- 修复阅读外观中的背景图片和字体选择;限制背景图片解码尺寸,降低内存占用。\n- 完善背景图片与预设主题切换,关闭背景图时保留已选图片。\n- 修复退出后重新进入阅读器的书签状态,避免重复添加书签。\n\n## 下载安装\n\n下载附件 **`legado-ios-v0.1.10-build16-unsigned.ipa`**,使用自己的签名工具安装。支持 TrollStore 的设备可自行安装;本项目暂不提供 App Store 或 TestFlight 分发。\n\n`Source code (zip / tar.gz)` 是源码,不能直接安装。附件 `SHA256SUMS` 可用于核对 IPA 完整性。\n\n## 验证与兼容\n\n本次通过 299 项核心及页面模型测试、12 项 iOS 阅读器测试、4 项文件导入与阅读操作 UI 回归,以及模拟器构建。IPA 由本次源码重新进行 iPhoneOS Release 构建。\n\niOS 15.7 真机尚未复测。若在该系统上仍遇到文件无法选择的问题,请继续在 [Issue #1](https://github.com/Aminark/legado-ios/issues/1) 反馈。\n\n**小浣熊阅读不提供、内置或分发网络书源,也不提供在线书库;书源需自行导入。**\n",
"downloadURL": "https://github.com/Aminark/legado-ios/releases/download/v0.1.10/legado-ios-v0.1.10-build16-unsigned.ipa",
"size": 12080513,
"minOSVersion": "15.0"
}
],
"version": "0.1.10",
"versionDate": "2026-10-20T15:34:03Z",
"versionDescription": "小浣熊阅读 **0.1.10**,构建号 **16**,支持 **iOS / iPadOS 15.0 及以上**。\n\n## 更新内容\n\n- 修复书源文件选择及导入流程:支持 JSON 多选,调整文件读取权限和导入预览展示时机(#1)。\n- 支持进入书源分组查看书源、打开详情及切换启用状态。\n- 修复阅读外观中的背景图片和字体选择;限制背景图片解码尺寸,降低内存占用。\n- 完善背景图片与预设主题切换,关闭背景图时保留已选图片。\n- 修复退出后重新进入阅读器的书签状态,避免重复添加书签。\n\n## 下载安装\n\n下载附件 **`legado-ios-v0.1.10-build16-unsigned.ipa`**,使用自己的签名工具安装。支持 TrollStore 的设备可自行安装;本项目暂不提供 App Store 或 TestFlight 分发。\n\n`Source code (zip / tar.gz)` 是源码,不能直接安装。附件 `SHA256SUMS` 可用于核对 IPA 完整性。\n\n## 验证与兼容\n\n本次通过 299 项核心及页面模型测试、12 项 iOS 阅读器测试、4 项文件导入与阅读操作 UI 回归,以及模拟器构建。IPA 由本次源码重新进行 iPhoneOS Release 构建。\n\niOS 15.7 真机尚未复测。若在该系统上仍遇到文件无法选择的问题,请继续在 [Issue #1](https://github.com/Aminark/legado-ios/issues/1) 反馈。\n\n**小浣熊阅读不提供、内置或分发网络书源,也不提供在线书库;书源需自行导入。**\n",
"downloadURL": "https://github.com/Aminark/legado-ios/releases/download/v0.1.10/legado-ios-v0.1.10-build16-unsigned.ipa",
"size": 12080513,
"appPermissions": {
"entitlements": [],
"privacy": {
"NSCameraUsageDescription": "用于扫描书源和净化规则的导入二维码。",
"NSPhotoLibraryAddUsageDescription": "用于保存阅读页面中的图片到照片图库。"
}
}
}
],
"news": []
}