diff --git a/.github/workflows/build-windows.yml b/.github/workflows/build-windows.yml index 5b26a0b..2b43062 100644 --- a/.github/workflows/build-windows.yml +++ b/.github/workflows/build-windows.yml @@ -113,10 +113,20 @@ jobs: # lib.rs looks for suwayomi-bundle/jre/bin/javaw.exe in the resource dir. cp -r suwayomi-extracted src-tauri/binaries/suwayomi-bundle - - name: Suppress frontend rebuild + - name: Patch tauri.conf.json for CI shell: bash run: | sed -i 's/"beforeBuildCommand": "pnpm build"/"beforeBuildCommand": ""/' src-tauri/tauri.conf.json + # Inject the suwayomi-bundle resource so Tauri bundles it with the app. + # Done here (after staging) so the path exists when Tauri validates it. + python3 - << 'PYEOF' +import json +with open("src-tauri/tauri.conf.json") as f: + conf = json.load(f) +conf["bundle"]["resources"] = ["binaries/suwayomi-bundle/**"] +with open("src-tauri/tauri.conf.json", "w") as f: + json.dump(conf, f, indent=2) +PYEOF - name: Build Tauri app (Windows x64) uses: tauri-apps/tauri-action@v0 diff --git a/src-tauri/tauri.conf.json b/src-tauri/tauri.conf.json index dcf6b16..f0d8864 100644 --- a/src-tauri/tauri.conf.json +++ b/src-tauri/tauri.conf.json @@ -44,10 +44,7 @@ "installerIcon": "icons/icon.ico", "installMode": "currentUser" } - }, - "resources": [ - "binaries/suwayomi-bundle/**" - ] + } }, "plugins": { "shell": {