From 0b6e9fbbbbe095a125b9ea3723f28f206aa00560 Mon Sep 17 00:00:00 2001 From: Youwes09 Date: Mon, 6 Apr 2026 20:44:34 -0500 Subject: [PATCH] Fix: Flatpak Binary Detection --- Todo | 18 +-- dev.moku.app.yml | 2 +- packaging/cargo-sources.json | 302 ++++++++++++++++++++++++++--------- src-tauri/src/lib.rs | 28 +++- 4 files changed, 260 insertions(+), 90 deletions(-) diff --git a/Todo b/Todo index befe78e..5d00593 100644 --- a/Todo +++ b/Todo @@ -10,14 +10,15 @@ Minor Revisions: - Look at how Manga are Organized in WebUI and Implement into Series-Detail (Chapter Display is Off) - Adjustment in Settings for Theme Editor: - Patch Color-Picker to Work Properly - - Moku Discord RPC - - Write a better library for Discord RPC & Tauri - - Integrate Download Directory Changes (Settings) + - Integrate Download Directory Changes (Settings) Priority Bugs: - Cache ALL Cover Pictures & Details for Manga in Library - Fix Library Build not Updating - Check Auth System (Only Supports Basic-Auth) + - Loading Buffer for Pictures (Due to Auth Lag) + - Create Option for Saved in Library to Respect Default Constraints + - Additionally, Added Folders are Displayed in Suwayomi, but not registered in Suwayomi General/Misc Bugs: @@ -30,14 +31,11 @@ General/Misc Bugs: In-Progress: - Enable Cloudflare Bypass (Suwayomi Config) (Requires Patching) - - - Patch Migrate Modal to Fill Language Options, not Limit to 7-9. + + - Add Scanlator Filtering -> Pass to Reader + - Automations need to work in Reader (Auto-Delete does not) -Testing: - - - Fix TitleBar not Appearing on Windows in Fullscreen (Locks in User) - - Integrate Download Directory Changes (Settings) - - Fix Source Allow in Content (Doesn't even work) \ No newline at end of file +Testing: \ No newline at end of file diff --git a/dev.moku.app.yml b/dev.moku.app.yml index 6c19492..07b1f4e 100644 --- a/dev.moku.app.yml +++ b/dev.moku.app.yml @@ -181,7 +181,7 @@ modules: path: . - type: file path: packaging/frontend-dist.tar.gz - sha256: d3ebde4d39e3de61420b78a9506df1a5c77c14d705e42662a45a2179bc96030e + sha256: a9be4a2b00de496e00fba4d7a113ef12357ea27d94942a96b6edaf8445cada30 - packaging/cargo-sources.json - type: inline dest: src-tauri/.cargo diff --git a/packaging/cargo-sources.json b/packaging/cargo-sources.json index aa5eeb4..8e67999 100644 --- a/packaging/cargo-sources.json +++ b/packaging/cargo-sources.json @@ -1,4 +1,10 @@ [ + { + "type": "git", + "url": "https://github.com/youwes09/tauri-plugin-discord-rpc", + "commit": "d2fd312945d0573153e0e7e2d2dfb131acecc52c", + "dest": "flatpak-cargo/git/tauri-plugin-discord-rpc-d2fd312" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -405,14 +411,14 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/cc/cc-1.2.58.crate", - "sha256": "e1e928d4b69e3077709075a938a05ffbedfa53a84c8f766efbf8220bb1ff60e1", - "dest": "cargo/vendor/cc-1.2.58" + "url": "https://static.crates.io/crates/cc/cc-1.2.59.crate", + "sha256": "b7a4d3ec6524d28a329fc53654bbadc9bdd7b0431f5d65f1a56ffb28a1ee5283", + "dest": "cargo/vendor/cc-1.2.59" }, { "type": "inline", - "contents": "{\"package\": \"e1e928d4b69e3077709075a938a05ffbedfa53a84c8f766efbf8220bb1ff60e1\", \"files\": {}}", - "dest": "cargo/vendor/cc-1.2.58", + "contents": "{\"package\": \"b7a4d3ec6524d28a329fc53654bbadc9bdd7b0431f5d65f1a56ffb28a1ee5283\", \"files\": {}}", + "dest": "cargo/vendor/cc-1.2.59", "dest-filename": ".cargo-checksum.json" }, { @@ -532,19 +538,6 @@ "dest": "cargo/vendor/cookie-0.18.1", "dest-filename": ".cargo-checksum.json" }, - { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/cookie_store/cookie_store-0.21.1.crate", - "sha256": "2eac901828f88a5241ee0600950ab981148a18f2f756900ffba1b125ca6a3ef9", - "dest": "cargo/vendor/cookie_store-0.21.1" - }, - { - "type": "inline", - "contents": "{\"package\": \"2eac901828f88a5241ee0600950ab981148a18f2f756900ffba1b125ca6a3ef9\", \"files\": {}}", - "dest": "cargo/vendor/cookie_store-0.21.1", - "dest-filename": ".cargo-checksum.json" - }, { "type": "archive", "archive-type": "tar-gzip", @@ -948,6 +941,19 @@ "dest": "cargo/vendor/dirs-sys-0.5.0", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/discord-rich-presence/discord-rich-presence-1.1.0.crate", + "sha256": "90c55d69cab17c19677ce3a5f8face993a9e6eaf847fecac3547f3a3ff4a2494", + "dest": "cargo/vendor/discord-rich-presence-1.1.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"90c55d69cab17c19677ce3a5f8face993a9e6eaf847fecac3547f3a3ff4a2494\", \"files\": {}}", + "dest": "cargo/vendor/discord-rich-presence-1.1.0", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -1185,14 +1191,14 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/fastrand/fastrand-2.3.0.crate", - "sha256": "37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be", - "dest": "cargo/vendor/fastrand-2.3.0" + "url": "https://static.crates.io/crates/fastrand/fastrand-2.4.0.crate", + "sha256": "a043dc74da1e37d6afe657061213aa6f425f855399a11d3463c6ecccc4dfda1f", + "dest": "cargo/vendor/fastrand-2.4.0" }, { "type": "inline", - "contents": "{\"package\": \"37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be\", \"files\": {}}", - "dest": "cargo/vendor/fastrand-2.3.0", + "contents": "{\"package\": \"a043dc74da1e37d6afe657061213aa6f425f855399a11d3463c6ecccc4dfda1f\", \"files\": {}}", + "dest": "cargo/vendor/fastrand-2.4.0", "dest-filename": ".cargo-checksum.json" }, { @@ -1299,6 +1305,19 @@ "dest": "cargo/vendor/foldhash-0.2.0", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/foreign-types/foreign-types-0.3.2.crate", + "sha256": "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1", + "dest": "cargo/vendor/foreign-types-0.3.2" + }, + { + "type": "inline", + "contents": "{\"package\": \"f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1\", \"files\": {}}", + "dest": "cargo/vendor/foreign-types-0.3.2", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -1325,6 +1344,19 @@ "dest": "cargo/vendor/foreign-types-macros-0.2.3", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/foreign-types-shared/foreign-types-shared-0.1.1.crate", + "sha256": "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b", + "dest": "cargo/vendor/foreign-types-shared-0.1.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b\", \"files\": {}}", + "dest": "cargo/vendor/foreign-types-shared-0.1.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -1975,6 +2007,19 @@ "dest": "cargo/vendor/hyper-rustls-0.27.7", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/hyper-tls/hyper-tls-0.6.0.crate", + "sha256": "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0", + "dest": "cargo/vendor/hyper-tls-0.6.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0\", \"files\": {}}", + "dest": "cargo/vendor/hyper-tls-0.6.0", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -2729,6 +2774,19 @@ "dest": "cargo/vendor/muda-0.17.2", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/native-tls/native-tls-0.2.18.crate", + "sha256": "465500e14ea162429d264d44189adc38b199b62b1c21eea9f69e4b73cb03bbf2", + "dest": "cargo/vendor/native-tls-0.2.18" + }, + { + "type": "inline", + "contents": "{\"package\": \"465500e14ea162429d264d44189adc38b199b62b1c21eea9f69e4b73cb03bbf2\", \"files\": {}}", + "dest": "cargo/vendor/native-tls-0.2.18", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -3028,6 +3086,19 @@ "dest": "cargo/vendor/objc2-foundation-0.3.2", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/objc2-io-kit/objc2-io-kit-0.3.2.crate", + "sha256": "33fafba39597d6dc1fb709123dfa8289d39406734be322956a69f0931c73bb15", + "dest": "cargo/vendor/objc2-io-kit-0.3.2" + }, + { + "type": "inline", + "contents": "{\"package\": \"33fafba39597d6dc1fb709123dfa8289d39406734be322956a69f0931c73bb15\", \"files\": {}}", + "dest": "cargo/vendor/objc2-io-kit-0.3.2", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -3132,6 +3203,32 @@ "dest": "cargo/vendor/open-5.3.3", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/openssl/openssl-0.10.76.crate", + "sha256": "951c002c75e16ea2c65b8c7e4d3d51d5530d8dfa7d060b4776828c88cfb18ecf", + "dest": "cargo/vendor/openssl-0.10.76" + }, + { + "type": "inline", + "contents": "{\"package\": \"951c002c75e16ea2c65b8c7e4d3d51d5530d8dfa7d060b4776828c88cfb18ecf\", \"files\": {}}", + "dest": "cargo/vendor/openssl-0.10.76", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/openssl-macros/openssl-macros-0.1.1.crate", + "sha256": "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c", + "dest": "cargo/vendor/openssl-macros-0.1.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c\", \"files\": {}}", + "dest": "cargo/vendor/openssl-macros-0.1.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -3145,6 +3242,19 @@ "dest": "cargo/vendor/openssl-probe-0.2.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/openssl-sys/openssl-sys-0.9.112.crate", + "sha256": "57d55af3b3e226502be1526dfdba67ab0e9c96fc293004e79576b2b9edb0dbdb", + "dest": "cargo/vendor/openssl-sys-0.9.112" + }, + { + "type": "inline", + "contents": "{\"package\": \"57d55af3b3e226502be1526dfdba67ab0e9c96fc293004e79576b2b9edb0dbdb\", \"files\": {}}", + "dest": "cargo/vendor/openssl-sys-0.9.112", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -4185,19 +4295,6 @@ "dest": "cargo/vendor/ring-0.17.14", "dest-filename": ".cargo-checksum.json" }, - { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/rpcdiscord/rpcdiscord-0.2.6.crate", - "sha256": "71aa9a2097dc0176805e24debcb5d3ea5a17b796cd1d28e76b29f78fb49d7d5d", - "dest": "cargo/vendor/rpcdiscord-0.2.6" - }, - { - "type": "inline", - "contents": "{\"package\": \"71aa9a2097dc0176805e24debcb5d3ea5a17b796cd1d28e76b29f78fb49d7d5d\", \"files\": {}}", - "dest": "cargo/vendor/rpcdiscord-0.2.6", - "dest-filename": ".cargo-checksum.json" - }, { "type": "archive", "archive-type": "tar-gzip", @@ -4487,14 +4584,14 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/semver/semver-1.0.27.crate", - "sha256": "d767eb0aabc880b29956c35734170f26ed551a859dbd361d140cdbeca61ab1e2", - "dest": "cargo/vendor/semver-1.0.27" + "url": "https://static.crates.io/crates/semver/semver-1.0.28.crate", + "sha256": "8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd", + "dest": "cargo/vendor/semver-1.0.28" }, { "type": "inline", - "contents": "{\"package\": \"d767eb0aabc880b29956c35734170f26ed551a859dbd361d140cdbeca61ab1e2\", \"files\": {}}", - "dest": "cargo/vendor/semver-1.0.27", + "contents": "{\"package\": \"8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd\", \"files\": {}}", + "dest": "cargo/vendor/semver-1.0.28", "dest-filename": ".cargo-checksum.json" }, { @@ -5082,6 +5179,19 @@ "dest": "cargo/vendor/sysinfo-0.32.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/sysinfo/sysinfo-0.36.1.crate", + "sha256": "252800745060e7b9ffb7b2badbd8b31cfa4aa2e61af879d0a3bf2a317c20217d", + "dest": "cargo/vendor/sysinfo-0.36.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"252800745060e7b9ffb7b2badbd8b31cfa4aa2e61af879d0a3bf2a317c20217d\", \"files\": {}}", + "dest": "cargo/vendor/sysinfo-0.36.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -5239,42 +5349,47 @@ "dest-filename": ".cargo-checksum.json" }, { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/tauri-plugin-drpc/tauri-plugin-drpc-0.1.6.crate", - "sha256": "7b291669b7dbc05471fba380eeecf31e3f733ae6013aaa5216a43ca376027e5a", - "dest": "cargo/vendor/tauri-plugin-drpc-0.1.6" + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/tauri-plugin-discord-rpc-d2fd312/.\" \"cargo/vendor/tauri-plugin-discord-rpc\"" + ] }, { "type": "inline", - "contents": "{\"package\": \"7b291669b7dbc05471fba380eeecf31e3f733ae6013aaa5216a43ca376027e5a\", \"files\": {}}", - "dest": "cargo/vendor/tauri-plugin-drpc-0.1.6", + "contents": "[package]\nname = \"tauri-plugin-discord-rpc\"\nversion = \"0.1.0\"\nauthors = [\"You\"]\ndescription = \"A Tauri plugin for Discord Rich Presence\"\nedition = \"2021\"\nrust-version = \"1.77.2\"\nexclude = [\"/examples\", \"/dist-js\", \"/guest-js\", \"/node_modules\"]\nlinks = \"tauri-plugin-discord-rpc\"\n\n[dependencies]\nserde_json = \"1.0\"\nthiserror = \"2\"\ndiscord-rich-presence = \"1.1.0\"\nlog = \"0.4\"\nlibc = \"0.2.184\"\n\n[dependencies.tauri]\nversion = \"2.10.3\"\n\n[dependencies.serde]\nversion = \"1.0\"\nfeatures = [\"derive\"]\n\n[dependencies.tokio]\nversion = \"1\"\nfeatures = [\"sync\", \"time\", \"rt\", \"macros\"]\n\n[dependencies.sysinfo]\nversion = \"0.36.1\"\ndefault-features = false\nfeatures = [\"system\"]\n\n[build-dependencies.tauri-plugin]\nversion = \"2.5.4\"\nfeatures = [\"build\"]\n", + "dest": "cargo/vendor/tauri-plugin-discord-rpc", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/tauri-plugin-discord-rpc", "dest-filename": ".cargo-checksum.json" }, { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/tauri-plugin-fs/tauri-plugin-fs-2.4.5.crate", - "sha256": "ed390cc669f937afeb8b28032ce837bac8ea023d975a2e207375ec05afaf1804", - "dest": "cargo/vendor/tauri-plugin-fs-2.4.5" + "url": "https://static.crates.io/crates/tauri-plugin-fs/tauri-plugin-fs-2.5.0.crate", + "sha256": "36e1ec28b79f3d0683f4507e1615c36292c0ea6716668770d4396b9b39871ed8", + "dest": "cargo/vendor/tauri-plugin-fs-2.5.0" }, { "type": "inline", - "contents": "{\"package\": \"ed390cc669f937afeb8b28032ce837bac8ea023d975a2e207375ec05afaf1804\", \"files\": {}}", - "dest": "cargo/vendor/tauri-plugin-fs-2.4.5", + "contents": "{\"package\": \"36e1ec28b79f3d0683f4507e1615c36292c0ea6716668770d4396b9b39871ed8\", \"files\": {}}", + "dest": "cargo/vendor/tauri-plugin-fs-2.5.0", "dest-filename": ".cargo-checksum.json" }, { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/tauri-plugin-http/tauri-plugin-http-2.5.7.crate", - "sha256": "d8f069451c4e87e7e2636b7f065a4c52866c4ce5e60e2d53fa1038edb6d184dc", - "dest": "cargo/vendor/tauri-plugin-http-2.5.7" + "url": "https://static.crates.io/crates/tauri-plugin-http/tauri-plugin-http-2.5.8.crate", + "sha256": "cfba7d4ec72763f9d1fdf73c217747f01e2c84b08b87a8cacd2f94f35853f84d", + "dest": "cargo/vendor/tauri-plugin-http-2.5.8" }, { "type": "inline", - "contents": "{\"package\": \"d8f069451c4e87e7e2636b7f065a4c52866c4ce5e60e2d53fa1038edb6d184dc\", \"files\": {}}", - "dest": "cargo/vendor/tauri-plugin-http-2.5.7", + "contents": "{\"package\": \"cfba7d4ec72763f9d1fdf73c217747f01e2c84b08b87a8cacd2f94f35853f84d\", \"files\": {}}", + "dest": "cargo/vendor/tauri-plugin-http-2.5.8", "dest-filename": ".cargo-checksum.json" }, { @@ -5319,14 +5434,14 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/tauri-plugin-updater/tauri-plugin-updater-2.10.0.crate", - "sha256": "3fe8e9bebd88fc222938ffdfbdcfa0307081423bd01e3252fc337d8bde81fc61", - "dest": "cargo/vendor/tauri-plugin-updater-2.10.0" + "url": "https://static.crates.io/crates/tauri-plugin-updater/tauri-plugin-updater-2.10.1.crate", + "sha256": "806d9dac662c2e4594ff03c647a552f2c9bd544e7d0f683ec58f872f952ce4af", + "dest": "cargo/vendor/tauri-plugin-updater-2.10.1" }, { "type": "inline", - "contents": "{\"package\": \"3fe8e9bebd88fc222938ffdfbdcfa0307081423bd01e3252fc337d8bde81fc61\", \"files\": {}}", - "dest": "cargo/vendor/tauri-plugin-updater-2.10.0", + "contents": "{\"package\": \"806d9dac662c2e4594ff03c647a552f2c9bd544e7d0f683ec58f872f952ce4af\", \"files\": {}}", + "dest": "cargo/vendor/tauri-plugin-updater-2.10.1", "dest-filename": ".cargo-checksum.json" }, { @@ -5553,27 +5668,40 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/tokio/tokio-1.50.0.crate", - "sha256": "27ad5e34374e03cfffefc301becb44e9dc3c17584f414349ebe29ed26661822d", - "dest": "cargo/vendor/tokio-1.50.0" + "url": "https://static.crates.io/crates/tokio/tokio-1.51.0.crate", + "sha256": "2bd1c4c0fc4a7ab90fc15ef6daaa3ec3b893f004f915f2392557ed23237820cd", + "dest": "cargo/vendor/tokio-1.51.0" }, { "type": "inline", - "contents": "{\"package\": \"27ad5e34374e03cfffefc301becb44e9dc3c17584f414349ebe29ed26661822d\", \"files\": {}}", - "dest": "cargo/vendor/tokio-1.50.0", + "contents": "{\"package\": \"2bd1c4c0fc4a7ab90fc15ef6daaa3ec3b893f004f915f2392557ed23237820cd\", \"files\": {}}", + "dest": "cargo/vendor/tokio-1.51.0", "dest-filename": ".cargo-checksum.json" }, { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/tokio-macros/tokio-macros-2.6.1.crate", - "sha256": "5c55a2eff8b69ce66c84f85e1da1c233edc36ceb85a2058d11b0d6a3c7e7569c", - "dest": "cargo/vendor/tokio-macros-2.6.1" + "url": "https://static.crates.io/crates/tokio-macros/tokio-macros-2.7.0.crate", + "sha256": "385a6cb71ab9ab790c5fe8d67f1645e6c450a7ce006a33de03daa956cf70a496", + "dest": "cargo/vendor/tokio-macros-2.7.0" }, { "type": "inline", - "contents": "{\"package\": \"5c55a2eff8b69ce66c84f85e1da1c233edc36ceb85a2058d11b0d6a3c7e7569c\", \"files\": {}}", - "dest": "cargo/vendor/tokio-macros-2.6.1", + "contents": "{\"package\": \"385a6cb71ab9ab790c5fe8d67f1645e6c450a7ce006a33de03daa956cf70a496\", \"files\": {}}", + "dest": "cargo/vendor/tokio-macros-2.7.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/tokio-native-tls/tokio-native-tls-0.3.1.crate", + "sha256": "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2", + "dest": "cargo/vendor/tokio-native-tls-0.3.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2\", \"files\": {}}", + "dest": "cargo/vendor/tokio-native-tls-0.3.1", "dest-filename": ".cargo-checksum.json" }, { @@ -5992,6 +6120,19 @@ "dest": "cargo/vendor/url-2.5.8", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/urlencoding/urlencoding-2.1.3.crate", + "sha256": "daf8dba3b7eb870caf1ddeed7bc9d2a049f3cfdfae7cb521b087cc33ae4c49da", + "dest": "cargo/vendor/urlencoding-2.1.3" + }, + { + "type": "inline", + "contents": "{\"package\": \"daf8dba3b7eb870caf1ddeed7bc9d2a049f3cfdfae7cb521b087cc33ae4c49da\", \"files\": {}}", + "dest": "cargo/vendor/urlencoding-2.1.3", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -6057,6 +6198,19 @@ "dest": "cargo/vendor/uuid-1.23.0", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/vcpkg/vcpkg-0.2.15.crate", + "sha256": "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426", + "dest": "cargo/vendor/vcpkg-0.2.15" + }, + { + "type": "inline", + "contents": "{\"package\": \"accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426\", \"files\": {}}", + "dest": "cargo/vendor/vcpkg-0.2.15", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -7658,7 +7812,7 @@ }, { "type": "inline", - "contents": "[source.vendored-sources]\ndirectory = \"cargo/vendor\"\n\n[source.crates-io]\nreplace-with = \"vendored-sources\"\n", + "contents": "[source.vendored-sources]\ndirectory = \"cargo/vendor\"\n\n[source.crates-io]\nreplace-with = \"vendored-sources\"\n\n[source.\"https://github.com/youwes09/tauri-plugin-discord-rpc\"]\ngit = \"https://github.com/youwes09/tauri-plugin-discord-rpc\"\nreplace-with = \"vendored-sources\"\n", "dest": "cargo", "dest-filename": "config" } diff --git a/src-tauri/src/lib.rs b/src-tauri/src/lib.rs index 1be1efd..a31372a 100644 --- a/src-tauri/src/lib.rs +++ b/src-tauri/src/lib.rs @@ -327,6 +327,22 @@ fn resolve_server_binary( do_log(log, "[resolve] user path not found, falling through"); } + if let Ok(exe) = std::env::current_exe() { + if let Some(bin_dir) = exe.parent() { + for name in &["tachidesk-server", "suwayomi-launcher"] { + let p = bin_dir.join(name); + do_log(log, &format!("[resolve] sibling: {:?} exists={}", p, p.exists())); + if p.exists() { + return Ok(ServerInvocation { + bin: p.to_string_lossy().into_owned(), + args: vec![], + working_dir: Some(bin_dir.to_path_buf()), + }); + } + } + } + } + #[cfg(not(target_os = "macos"))] let resource_dir = { let raw = app.path().resource_dir().unwrap_or_default(); @@ -458,11 +474,13 @@ fn spawn_server(binary: String, app: tauri::AppHandle) -> Result<(), SpawnError> e })?; - let rootdir_flag = format!( - "-Dsuwayomi.tachidesk.config.server.rootDir={}", - data_dir.to_string_lossy() - ); - invocation.args.insert(0, rootdir_flag); + if invocation.bin.ends_with("java") || invocation.bin.ends_with("java.exe") { + let rootdir_flag = format!( + "-Dsuwayomi.tachidesk.config.server.rootDir={}", + data_dir.to_string_lossy() + ); + invocation.args.insert(0, rootdir_flag); + } let working_dir = invocation.working_dir.unwrap_or_else(|| std::env::current_dir().unwrap_or_default());