Release #11
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
# 控制工作流何时运行 | |
on: | |
#push: | |
# branches: [ "main" ] | |
repository_dispatch: | |
types: [release] | |
# 允许手动运行工作流 | |
workflow_dispatch: | |
env: | |
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
# 下载LSPatch | |
- name: Download LSPatch | |
run: gh release download --repo LSPosed/LSPatch --pattern lspatch.jar | |
# 下载待修补的应用 | |
- name: 下载QQ 8.9.58 | |
# 官方直链 run: wget -O QQ8.9.58. https://downv6.qq.com/qqweb/QQ_1/android_apk/Android_8.9.58_64_HB2.apk | |
run: gh release download -O QQ-8.9.58.apk --repo Hakuin123/MQGA READY --pattern QQ_8.9.58_64_HB2.apk | |
# 使用GitHub CLI下载模块最新Release版本 | |
- name: 下载模块 | |
run: | | |
gh release download -O QAuxiliary.apk --repo cinit/QAuxiliary --pattern '*-arm64.apk' | |
gh release download -O XAutoDaily.apk --repo LuckyPray/XAutoDaily --pattern '*.apk' | |
gh release download -O TSBattery.apk --repo fankes/TSBattery --pattern 'app-release.apk' | |
gh release download -O QQCleaner.apk --repo KitsunePie/QQCleaner --pattern 'app-release.apk' | |
# 开始修补应用 | |
- name: 修补应用 | |
run: java -jar lspatch.jar QQ-8.9.58.apk -m QAuxiliary.apk,XAutoDaily.apk,TSBattery.apk,QQCleaner.apk -l 2 | |
# 上传修补完成的文件 | |
#- name: 上传修补完成的文件 | |
# uses: actions/upload-artifact@v3 | |
# with: | |
# name: QQ-8.9.58-Release | |
# path: QQ-8.9.58-360-lspatched.apk | |
# 发布Release以便下载 | |
- name: Draft Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
files: QQ-8.9.58-360-lspatched.apk | |
tag_name: QQ Releases ${{ github.run_id }} | |
name: QQ Releases ${{ github.run_id }} | |
body: 仅在此发布最新修补的Release版本 | |
- name: 下载最新版QQ | |
run: wget -U "Mozilla/5.0" -O QQ-latest.apk https://d.apkpure.com/b/APK/com.tencent.mobileqq?version=latest | |
# 由于QQ官方未给出下载最新版本的固定链接,故使用APKPure提供下载 | |
# 酷安 run: wget -O QQ-latest.apk 'https://dl.coolapk.com/down?pn=com.tencent.mobileqq&id=MzgzNA&h=aefedf55ryt58j' | |
# 豌豆荚(有固定链接但更新不及时) run: wget -O QQ-latest.apk https://www.wandoujia.com/apps/566489/download | |
# 开始修补应用 | |
- name: 修补应用 | |
run: java -jar lspatch.jar QQ-latest.apk -m QAuxiliary.apk,XAutoDaily.apk,TSBattery.apk,QQCleaner.apk -l 2 | |
# 再次发布Release | |
- name: Draft Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
files: QQ-latest-360-lspatched.apk | |
tag_name: QQ Releases ${{ github.run_id }} | |
name: QQ Releases ${{ github.run_id }} | |
body: 标有“latest”的是基于最新版本修补的版本 | |
append_body: true |