Skip to content

The only downloader you need. 下载器的集大成者。

ci(android): 缓存 key 改用脚本解析出的依赖版本

XiaoYouChRb94c8d8bf92d
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index ce08f9e1..1977c5f3 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -787,16 +787,17 @@ jobs:
with:
python-version: '3.14'
- - name: Read libtorrent version
+ - name: Resolve libtorrent wheel versions
id: libtorrent
- run: echo "version=$(python3 -c "import tomllib; print(next(p['version'] for p in tomllib.load(open('uv.lock', 'rb'))['package'] if p['name'] == 'libtorrent'))")" >> "$GITHUB_OUTPUT"
+ working-directory: android/build-scripts
+ run: echo "versions=$(./build_libtorrent_wheel.sh --print-versions)" >> "$GITHUB_OUTPUT"
- name: Cache libtorrent wheel
id: libtorrent-cache
uses: actions/cache@v6
with:
path: android/build-scripts/dist
- key: libtorrent-android-arm64-v8a-${{ steps.libtorrent.outputs.version }}-${{ hashFiles('android/build-scripts/build_libtorrent_wheel.sh') }}
+ key: libtorrent-android-arm64-v8a-${{ steps.libtorrent.outputs.versions }}-${{ hashFiles('android/build-scripts/build_libtorrent_wheel.sh') }}
- name: Install wheel tool
if: ${{ steps.libtorrent-cache.outputs.cache-hit != 'true' }}