diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml new file mode 100644 index 00000000..1fc6de86 --- /dev/null +++ b/.github/workflows/integration-tests.yml @@ -0,0 +1,29 @@ +name: integration tests + +on: + push: + branches: + - main + pull_request: + branches: + - main + +jobs: + run-integration-tests: + runs-on: ${{ matrix.platform }} + + strategy: + fail-fast: false + matrix: + platform: [ubuntu-latest, macos-latest, windows-latest] + + steps: + - uses: actions/checkout@v4 + - name: install webkit2gtk + if: matrix.platform == 'ubuntu-latest' + run: | + sudo apt-get update + sudo apt-get install -y fuse libfuse2 + - uses: dtolnay/rust-toolchain@stable + - uses: Swatinem/rust-cache@v2 + - run: cargo test --test '*' -- --ignored --nocapture diff --git a/Cargo.lock b/Cargo.lock index 7bf186e3..df1fb2b0 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4,9 +4,9 @@ version = 3 [[package]] name = "ab_glyph" -version = "0.2.22" +version = "0.2.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1061f3ff92c2f65800df1f12fc7b4ff44ee14783104187dd04dfee6f11b0fd2" +checksum = "80179d7dd5d7e8c285d67c4a1e652972a92de7475beddfb92028c76463b13225" dependencies = [ "ab_glyph_rasterizer", "owned_ttf_parser", @@ -24,13 +24,28 @@ version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "76eb1adf08c5bcaa8490b9851fd53cca27fa9880076f178ea9d29f05196728a8" +[[package]] +name = "accesskit" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca8410747ed85a17c4a1e9ed3f5a74d3e7bdcc876cf9a18ff40ae21d645997b2" + [[package]] name = "accesskit_consumer" version = "0.15.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "04bb4d9e4772fe0d47df57d0d5dbe5d85dd05e2f37ae1ddb6b105e76be58fb00" dependencies = [ - "accesskit", + "accesskit 0.11.2", +] + +[[package]] +name = "accesskit_consumer" +version = "0.16.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8c17cca53c09fbd7288667b22a201274b9becaa27f0b91bf52a526db95de45e6" +dependencies = [ + "accesskit 0.12.1", ] [[package]] @@ -39,9 +54,21 @@ version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "134d0acf6acb667c89d3332999b1a5df4edbc8d6113910f392ebb73f2b03bb56" dependencies = [ - "accesskit", - "accesskit_consumer", - "objc2", + "accesskit 0.11.2", + "accesskit_consumer 0.15.2", + "objc2 0.3.0-beta.3.patch-leaks.3", + "once_cell", +] + +[[package]] +name = "accesskit_macos" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cd3b6ae1eabbfbced10e840fd3fce8a93ae84f174b3e4ba892ab7bcb42e477a7" +dependencies = [ + "accesskit 0.12.1", + "accesskit_consumer 0.16.1", + "objc2 0.3.0-beta.3.patch-leaks.3", "once_cell", ] @@ -51,11 +78,28 @@ version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e084cb5168790c0c112626175412dc5ad127083441a8248ae49ddf6725519e83" dependencies = [ - "accesskit", - "accesskit_consumer", - "async-channel", - "atspi", - "futures-lite", + "accesskit 0.11.2", + "accesskit_consumer 0.15.2", + "async-channel 1.9.0", + "atspi 0.10.1", + "futures-lite 1.13.0", + "serde", + "zbus", +] + +[[package]] +name = "accesskit_unix" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c8c9b4467d77cacfbc93cee9aa8e7822f6d527c774efdca5f8b3a5280c34847" +dependencies = [ + "accesskit 0.12.1", + "accesskit_consumer 0.16.1", + "async-channel 1.9.0", + "async-once-cell", + "atspi 0.19.0", + "futures-lite 1.13.0", + "once_cell", "serde", "zbus", ] @@ -66,25 +110,52 @@ version = "0.14.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9eac0a7f2d7cd7a93b938af401d3d8e8b7094217989a7c25c55a953023436e31" dependencies = [ - "accesskit", - "accesskit_consumer", + "accesskit 0.11.2", + "accesskit_consumer 0.15.2", "arrayvec", "once_cell", "paste", "windows 0.48.0", ] +[[package]] +name = "accesskit_windows" +version = "0.15.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "afcae27ec0974fc7c3b0b318783be89fd1b2e66dd702179fe600166a38ff4a0b" +dependencies = [ + "accesskit 0.12.1", + "accesskit_consumer 0.16.1", + "once_cell", + "paste", + "static_assertions", + "windows 0.48.0", +] + [[package]] name = "accesskit_winit" version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "825d23acee1bd6d25cbaa3ca6ed6e73faf24122a774ec33d52c5c86c6ab423c0" dependencies = [ - "accesskit", - "accesskit_macos", - "accesskit_unix", - "accesskit_windows", - "winit", + "accesskit 0.11.2", + "accesskit_macos 0.9.0", + "accesskit_unix 0.5.2", + "accesskit_windows 0.14.3", + "winit 0.28.7", +] + +[[package]] +name = "accesskit_winit" +version = "0.16.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5284218aca17d9e150164428a0ebc7b955f70e3a9a78b4c20894513aabf98a67" +dependencies = [ + "accesskit 0.12.1", + "accesskit_macos 0.10.1", + "accesskit_unix 0.6.1", + "accesskit_windows 0.15.1", + "winit 0.29.3", ] [[package]] @@ -115,6 +186,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "91429305e9f0a25f6205c5b8e0d2db09e0708a7a6df0f42212bb56c32c8ac97a" dependencies = [ "cfg-if", + "getrandom 0.2.11", "once_cell", "version_check", "zerocopy", @@ -122,9 +194,9 @@ dependencies = [ [[package]] name = "aho-corasick" -version = "1.1.1" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea5d730647d4fadd988536d06fecce94b7b4f2a7efdae548f1cf4b63205518ab" +checksum = "b2969dcb958b36655471fc61f7e416fa76033bdd4bfed0678d8fee1e2d07a1f0" dependencies = [ "memchr", ] @@ -162,6 +234,27 @@ dependencies = [ "num_enum 0.6.1", ] +[[package]] +name = "android-activity" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "052ad56e336bcc615a214bffbeca6c181ee9550acec193f0327e0b103b033a4d" +dependencies = [ + "android-properties", + "bitflags 2.4.1", + "cc", + "cesu8", + "jni 0.21.1", + "jni-sys", + "libc", + "log", + "ndk 0.8.0", + "ndk-context", + "ndk-sys 0.5.0+25.2.9519653", + "num_enum 0.7.1", + "thiserror", +] + [[package]] name = "android-properties" version = "0.2.2" @@ -278,13 +371,19 @@ version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2d5f312b0a56c5cdf967c0aeb67f6289603354951683bc97ddc595ab974ba9aa" +[[package]] +name = "ascii" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d92bec98840b8f03a5ff5413de5293bfcd8bf96467cf5452609f939ec6f5de16" + [[package]] name = "async-broadcast" version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7c48ccdbf6ca6b121e0f586cbc0e73ae440e56c67c30fa0873b4e110d9c26d2b" dependencies = [ - "event-listener", + "event-listener 2.5.3", "futures-core", ] @@ -295,21 +394,34 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "81953c529336010edd6d8e358f886d9581267795c61b19475b71314bffa46d35" dependencies = [ "concurrent-queue", - "event-listener", + "event-listener 2.5.3", + "futures-core", +] + +[[package]] +name = "async-channel" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d37875bd9915b7d67c2f117ea2c30a0989874d0b2cb694fe25403c85763c0c9e" +dependencies = [ + "concurrent-queue", + "event-listener 3.1.0", + "event-listener-strategy", "futures-core", + "pin-project-lite", ] [[package]] name = "async-executor" -version = "1.5.4" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c1da3ae8dabd9c00f453a329dfe1fb28da3c0a72e2478cdcd93171740c20499" +checksum = "4b0c4a4f319e45986f347ee47fef8bf5e81c9abc3f6f58dc2391439f30df65f0" dependencies = [ - "async-lock", + "async-lock 2.8.0", "async-task", "concurrent-queue", "fastrand 2.0.1", - "futures-lite", + "futures-lite 1.13.0", "slab", ] @@ -319,10 +431,10 @@ version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "279cf904654eeebfa37ac9bb1598880884924aab82e290aa65c9e77a0e142e06" dependencies = [ - "async-lock", + "async-lock 2.8.0", "autocfg", "blocking", - "futures-lite", + "futures-lite 1.13.0", ] [[package]] @@ -331,18 +443,38 @@ version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0fc5b45d93ef0529756f812ca52e44c221b35341892d3dcc34132ac02f3dd2af" dependencies = [ - "async-lock", + "async-lock 2.8.0", "autocfg", "cfg-if", "concurrent-queue", - "futures-lite", + "futures-lite 1.13.0", "log", "parking", - "polling", - "rustix 0.37.24", + "polling 2.8.0", + "rustix 0.37.27", + "slab", + "socket2 0.4.10", + "waker-fn", +] + +[[package]] +name = "async-io" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41ed9d5715c2d329bf1b4da8d60455b99b187f27ba726df2883799af9af60997" +dependencies = [ + "async-lock 3.1.0", + "cfg-if", + "concurrent-queue", + "futures-io", + "futures-lite 2.0.1", + "parking", + "polling 3.3.0", + "rustix 0.38.24", "slab", - "socket2 0.4.9", + "tracing", "waker-fn", + "windows-sys 0.48.0", ] [[package]] @@ -351,24 +483,40 @@ version = "2.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "287272293e9d8c41773cec55e365490fe034813a2f172f502d6ddcf75b2f582b" dependencies = [ - "event-listener", + "event-listener 2.5.3", ] +[[package]] +name = "async-lock" +version = "3.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "deb2ab2aa8a746e221ab826c73f48bc6ba41be6763f0855cb249eb6d154cf1d7" +dependencies = [ + "event-listener 3.1.0", + "event-listener-strategy", + "pin-project-lite", +] + +[[package]] +name = "async-once-cell" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9338790e78aa95a416786ec8389546c4b6a1dfc3dc36071ed9518a9413a542eb" + [[package]] name = "async-process" -version = "1.7.0" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a9d28b1d97e08915212e2e45310d47854eafa69600756fc735fb788f75199c9" +checksum = "ea6438ba0a08d81529c69b36700fa2f95837bfe3e776ab39cde9c14d9149da88" dependencies = [ - "async-io", - "async-lock", - "autocfg", + "async-io 1.13.0", + "async-lock 2.8.0", + "async-signal", "blocking", "cfg-if", - "event-listener", - "futures-lite", - "rustix 0.37.24", - "signal-hook", + "event-listener 3.1.0", + "futures-lite 1.13.0", + "rustix 0.38.24", "windows-sys 0.48.0", ] @@ -380,24 +528,42 @@ checksum = "5fd55a5ba1179988837d24ab4c7cc8ed6efdeff578ede0416b4225a5fca35bd0" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", +] + +[[package]] +name = "async-signal" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9e47d90f65a225c4527103a8d747001fc56e375203592b25ad103e1ca13124c5" +dependencies = [ + "async-io 2.2.0", + "async-lock 2.8.0", + "atomic-waker", + "cfg-if", + "futures-core", + "futures-io", + "rustix 0.38.24", + "signal-hook-registry", + "slab", + "windows-sys 0.48.0", ] [[package]] name = "async-task" -version = "4.4.1" +version = "4.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9441c6b2fe128a7c2bf680a44c34d0df31ce09e5b7e401fcca3faa483dbc921" +checksum = "b4eb2cdb97421e01129ccb49169d8279ed21e829929144f4a22a6e54ac549ca1" [[package]] name = "async-trait" -version = "0.1.73" +version = "0.1.74" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc00ceb34980c03614e35a3a4e218276a0a824e911d07651cd0d858a51e8c0f0" +checksum = "a66537f1bb974b254c98ed142ff995236e81b9d0fe4db0575f46612cb15eb0f9" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -441,9 +607,9 @@ checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" [[package]] name = "atomic_refcell" -version = "0.1.12" +version = "0.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76f2bfe491d41d45507b8431da8274f7feeca64a49e86d980eed2937ec2ff020" +checksum = "41e67cd8309bbd06cd603a9e693a784ac2e5d1e955f11286e355089fcab3047c" [[package]] name = "atspi" @@ -455,13 +621,50 @@ dependencies = [ "async-trait", "atspi-macros", "enumflags2", - "futures-lite", + "futures-lite 1.13.0", "serde", "tracing", "zbus", "zbus_names", ] +[[package]] +name = "atspi" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6059f350ab6f593ea00727b334265c4dfc7fd442ee32d264794bd9bdc68e87ca" +dependencies = [ + "atspi-common", + "atspi-connection", + "atspi-proxies", +] + +[[package]] +name = "atspi-common" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "92af95f966d2431f962bc632c2e68eda7777330158bf640c4af4249349b2cdf5" +dependencies = [ + "enumflags2", + "serde", + "static_assertions", + "zbus", + "zbus_names", + "zvariant", +] + +[[package]] +name = "atspi-connection" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a0c65e7d70f86d4c0e3b2d585d9bf3f979f0b19d635a336725a88d279f76b939" +dependencies = [ + "atspi-common", + "atspi-proxies", + "futures-lite 1.13.0", + "zbus", +] + [[package]] name = "atspi-macros" version = "0.2.0" @@ -472,16 +675,27 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "atspi-proxies" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6495661273703e7a229356dcbe8c8f38223d697aacfaf0e13590a9ac9977bb52" +dependencies = [ + "atspi-common", + "serde", + "zbus", +] + [[package]] name = "auto_enums" -version = "0.8.2" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd4ba50b181a898ce52142184e3a46641002b3b190bf5ef827eb3c578fad4b70" +checksum = "a764179c02b324e33cf71b4180e7dd13572400ff7e5c866da813f6c84e0e4cd3" dependencies = [ "derive_utils", "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -513,9 +727,9 @@ checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" [[package]] name = "base64" -version = "0.21.4" +version = "0.21.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ba43ea6f343b788c8764558649e08df62f86c6ef251fdaeb1ffd010a9ae50a2" +checksum = "35636a1494ede3b646cc98f74f8e62c773a38a659ebc777a2cf26b9b74171df9" [[package]] name = "bindgen" @@ -523,7 +737,7 @@ version = "0.68.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "726e4313eb6ec35d2730258ad4e15b547ee75d6afaa1361a922e78e59b7d8078" dependencies = [ - "bitflags 2.4.0", + "bitflags 2.4.1", "cexpr", "clang-sys", "lazy_static", @@ -536,7 +750,7 @@ dependencies = [ "regex", "rustc-hash", "shlex", - "syn 2.0.37", + "syn 2.0.39", "which", ] @@ -554,9 +768,9 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.4.0" +version = "2.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4682ae6287fcf752ecaabbfcc7b6f9b72aa33933dc23a554d853aea8eea8635" +checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" [[package]] name = "block" @@ -579,7 +793,16 @@ version = "0.1.0-beta.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0fa55741ee90902547802152aaf3f8e5248aab7e21468089560d4c8840561146" dependencies = [ - "objc-sys", + "objc-sys 0.2.0-beta.2", +] + +[[package]] +name = "block-sys" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2dd7cf50912cddc06dc5ea7c08c5e81c1b2c842a70d19def1848d54c586fed92" +dependencies = [ + "objc-sys 0.3.1", ] [[package]] @@ -588,22 +811,32 @@ version = "0.2.0-alpha.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8dd9e63c1744f755c2f60332b88de39d341e5e86239014ad839bd71c106dec42" dependencies = [ - "block-sys", - "objc2-encode", + "block-sys 0.1.0-beta.1", + "objc2-encode 2.0.0-pre.2", +] + +[[package]] +name = "block2" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "15b55663a85f33501257357e6421bb33e769d5c9ffb5ba0921c975a123e35e68" +dependencies = [ + "block-sys 0.2.0", + "objc2 0.4.1", ] [[package]] name = "blocking" -version = "1.4.0" +version = "1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94c4ef1f913d78636d78d538eec1f18de81e481f44b1be0a81060090530846e1" +checksum = "6a37913e8dc4ddcc604f0c6d3bf2887c995153af3611de9e23c352b44c1b9118" dependencies = [ - "async-channel", - "async-lock", + "async-channel 2.1.0", + "async-lock 3.1.0", "async-task", "fastrand 2.0.1", "futures-io", - "futures-lite", + "futures-lite 2.0.1", "piper", "tracing", ] @@ -621,9 +854,9 @@ dependencies = [ [[package]] name = "brotli-decompressor" -version = "2.5.0" +version = "2.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da74e2b81409b1b743f8f0c62cc6254afefb8b8e50bbfe3735550f7aeefa3448" +checksum = "4e2e4afe60d7dd600fdd3de8d0f08c2b7ec039712e3b6137ff98b7004e82de4f" dependencies = [ "alloc-no-stdlib", "alloc-stdlib", @@ -658,14 +891,14 @@ checksum = "965ab7eb5f8f97d2a083c799f3a1b994fc397b2fe2da5d1da1626ce15a39f2b1" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] name = "byteorder" -version = "1.4.3" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" @@ -725,11 +958,37 @@ dependencies = [ "io-lifetimes", "log", "nix 0.26.4", - "polling", + "polling 2.8.0", "slab", "thiserror", ] +[[package]] +name = "calloop" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b50b5a44d59a98c55a9eeb518f39bf7499ba19fd98ee7d22618687f3f10adbf" +dependencies = [ + "bitflags 2.4.1", + "log", + "polling 3.3.0", + "rustix 0.38.24", + "slab", + "thiserror", +] + +[[package]] +name = "calloop-wayland-source" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0f0ea9b9476c7fad82841a8dbb380e2eae480c21910feba80725b46931ed8f02" +dependencies = [ + "calloop 0.12.3", + "rustix 0.38.24", + "wayland-backend", + "wayland-client 0.31.1", +] + [[package]] name = "camino" version = "1.1.6" @@ -744,7 +1003,7 @@ name = "cargo-packager" version = "0.3.0" dependencies = [ "ar", - "base64 0.21.4", + "base64 0.21.5", "cargo_metadata", "clap", "dirs", @@ -775,7 +1034,7 @@ dependencies = [ "tempfile", "thiserror", "time", - "toml 0.8.2", + "toml 0.8.8", "tracing", "tracing-subscriber", "ureq", @@ -798,21 +1057,47 @@ dependencies = [ [[package]] name = "cargo-packager-updater" version = "0.0.0" +dependencies = [ + "base64 0.21.5", + "ctor 0.2.5", + "dirs", + "dunce", + "flate2", + "http", + "minisign-verify", + "reqwest", + "semver", + "serde", + "serde_json", + "tar", + "tempfile", + "thiserror", + "time", + "tiny_http", + "url", +] + +[[package]] +name = "cargo-packager-updater-app-test" +version = "0.1.0" +dependencies = [ + "cargo-packager-updater", +] [[package]] name = "cargo-platform" -version = "0.1.3" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2cfa25e60aea747ec7e1124f238816749faa93759c6ff5b31f1ccdda137f4479" +checksum = "12024c4645c97566567129c204f65d5815a8c9aecf30fcbe682b2fe034996d36" dependencies = [ "serde", ] [[package]] name = "cargo_metadata" -version = "0.18.0" +version = "0.18.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb9ac64500cc83ce4b9f8dafa78186aa008c8dea77a09b94cd307fd0cd5022a8" +checksum = "2d886547e41f740c616ae73108f6eb70afe6d940c7bc697cb30f13daec073037" dependencies = [ "camino", "cargo-platform", @@ -912,6 +1197,12 @@ dependencies = [ "windows-targets 0.48.5", ] +[[package]] +name = "chunked_transfer" +version = "1.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cca491388666e04d7248af3f60f0c40cfb0991c72205595d7c396e3510207d1a" + [[package]] name = "cipher" version = "0.4.4" @@ -935,9 +1226,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.4.6" +version = "4.4.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d04704f56c2cde07f43e8e2c154b43f216dc5c92fc98ada720177362f953b956" +checksum = "2275f18819641850fa26c89acc84d465c1bf91ce57bc2748b28c420473352f64" dependencies = [ "clap_builder", "clap_derive", @@ -945,9 +1236,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.4.6" +version = "4.4.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e231faeaca65ebd1ea3c737966bf858971cd38c3849107aa3ea7de90a804e45" +checksum = "07cdf1b148b25c1e1f7a42225e30a0d99a615cd4637eae7365548dd4529b95bc" dependencies = [ "anstream", "anstyle", @@ -957,21 +1248,21 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.4.2" +version = "4.4.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0862016ff20d69b84ef8247369fabf5c008a7417002411897d40ee1f4532b873" +checksum = "cf9804afaaf59a91e75b022a30fb7229a7901f60c755489cc61c9b423b836442" dependencies = [ "heck", "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] name = "clap_lex" -version = "0.5.1" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd7cc57abe963c6d3b9d8be5b06ba7c8957a930305ca90304f24ef040aa6f961" +checksum = "702fc72eb24e5a1e48ce58027a675bc24edd52096d5397d4aea7c6dd9eca0bd1" [[package]] name = "clipboard-win" @@ -1111,7 +1402,7 @@ checksum = "57aaaad9185d3bcb3afe63549d8ba60b2fb0ea8dc2da83f62dd56805edf56fd1" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -1131,15 +1422,15 @@ dependencies = [ [[package]] name = "copypasta" -version = "0.8.2" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "133fc8675ee3a4ec9aa513584deda9aa0faeda3586b87f7f0f2ba082c66fb172" +checksum = "6d35364349bf9e9e1c3a035ddcb00d188d23a3c40c50244c03c27a99fc6a65ae" dependencies = [ "clipboard-win 3.1.1", "objc", "objc-foundation", "objc_id", - "smithay-clipboard", + "smithay-clipboard 0.7.0", "x11-clipboard", ] @@ -1243,7 +1534,7 @@ dependencies = [ "lazy_static", "proc-macro2", "regex", - "syn 2.0.37", + "syn 2.0.39", "unicode-xid", ] @@ -1255,7 +1546,7 @@ checksum = "3e1a2532e4ed4ea13031c13bc7bc0dbca4aae32df48e9d77f0d1e743179f2ea1" dependencies = [ "lazy_static", "proc-macro2", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -1270,14 +1561,14 @@ dependencies = [ "lazy_static", "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] name = "cpufeatures" -version = "0.2.9" +version = "0.2.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a17b76ff3a4162b0b27f354a0c87015ddad39d35f9c0c36607a3bdd175dde1f1" +checksum = "ce420fe07aecd3e67c5f910618fe65e94158f6dcc0adf44e00d69ce2bdfe0fd0" dependencies = [ "libc", ] @@ -1401,7 +1692,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "13b588ba4ac1a99f7f2964d24b3d896ddc6bf847ee3855dbd4366f058cfcd331" dependencies = [ "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -1421,9 +1712,15 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "37e366bff8cd32dd8754b0991fb66b279dc48f598c3a18914852a6673deef583" dependencies = [ "quote", - "syn 2.0.37", + "syn 2.0.39", ] +[[package]] +name = "cursor-icon" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96a6ac251f4a2aca6b3f91340350eab87ae57c3f127ffeb585e92bd336717991" + [[package]] name = "darling" version = "0.20.3" @@ -1445,7 +1742,7 @@ dependencies = [ "proc-macro2", "quote", "strsim", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -1456,7 +1753,7 @@ checksum = "836a9bbc7ad63342d6d6e7b815ccab164bc77a2d95d84bc3117a8c0d5c98e2d5" dependencies = [ "darling_core", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -1473,10 +1770,11 @@ checksum = "8d7439c3735f405729d52c3fbbe4de140eaf938a1fe47d227c27f8254d4302a5" [[package]] name = "deranged" -version = "0.3.8" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2696e8a945f658fd14dc3b87242e6b80cd0f36ff04ea560fa39082368847946" +checksum = "0f32d04922c60427da6f9fef14d042d9edddef64cb9d4ce0d64d0685fbeb1fd3" dependencies = [ + "powerfmt", "serde", ] @@ -1512,7 +1810,7 @@ checksum = "9abcad25e9720609ccb3dcdb795d845e37d8ce34183330a9f48b03a1a71c8e21" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -1566,7 +1864,7 @@ dependencies = [ "dioxus-rsx", "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -1647,7 +1945,7 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fb712fe56650dafddb626f8aed3d6ae194706c0299e175e99b45464add8b7af1" dependencies = [ - "async-channel", + "async-channel 1.9.0", "async-trait", "dioxus-core", "enumset", @@ -1676,7 +1974,7 @@ dependencies = [ "dioxus-core", "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -1817,9 +2115,9 @@ dependencies = [ [[package]] name = "dyn-clone" -version = "1.0.14" +version = "1.0.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23d2f3407d9a573d666de4b5bdf10569d73ca9478087346697dcbae6244bfbcd" +checksum = "545b22097d44f8a9581187cdf93de7a71e4722bf51200cfaba810865b49a495d" [[package]] name = "ecolor" @@ -1842,20 +2140,20 @@ dependencies = [ "egui-winit", "egui_glow", "glow", - "glutin", - "glutin-winit", + "glutin 0.30.10", + "glutin-winit 0.3.0", "image", "js-sys", "log", "objc", "percent-encoding", - "raw-window-handle", + "raw-window-handle 0.5.2", "thiserror", "wasm-bindgen", "wasm-bindgen-futures", "web-sys", "winapi", - "winit", + "winit 0.28.7", ] [[package]] @@ -1864,7 +2162,7 @@ version = "0.22.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a3aef8ec3ae1b772f340170c65bf27d5b8c28f543a0116c844d2ac08d01123e7" dependencies = [ - "accesskit", + "accesskit 0.11.2", "ahash", "epaint", "log", @@ -1884,15 +2182,15 @@ version = "0.22.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4a49155fd4a0a4fb21224407a91de0030847972ef90fc64edb63621caea61cb2" dependencies = [ - "accesskit_winit", + "accesskit_winit 0.14.4", "arboard", "egui", "instant", "log", - "raw-window-handle", - "smithay-clipboard", + "raw-window-handle 0.5.2", + "smithay-clipboard 0.6.6", "webbrowser", - "winit", + "winit 0.28.7", ] [[package]] @@ -1927,13 +2225,13 @@ dependencies = [ [[package]] name = "embed-resource" -version = "2.3.0" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd0a2c9b742a980060d22545a7a83b573acd6b73045b9de6370c9530ce652f27" +checksum = "f54cc3e827ee1c3812239a9a41dede7b4d7d5d5464faa32d71bd7cba28ce2cb2" dependencies = [ "cc", "rustc_version", - "toml 0.7.8", + "toml 0.8.8", "vswhom", "winreg 0.51.0", ] @@ -1971,14 +2269,14 @@ checksum = "f95e2801cd355d4a1a3e3953ce6ee5ae9603a5c833455343a8bfe3f44d418246" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] name = "enumset" -version = "1.1.2" +version = "1.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e875f1719c16de097dee81ed675e2d9bb63096823ed3f0ca827b7dea3028bbbb" +checksum = "226c0da7462c13fb57e5cc9e0dc8f0635e7d27f276a3a7fd30054647f669007d" dependencies = [ "enumset_derive", ] @@ -1992,7 +2290,7 @@ dependencies = [ "darling", "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -2020,25 +2318,14 @@ checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" [[package]] name = "errno" -version = "0.3.4" +version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "add4f07d43996f76ef320709726a556a9d4f965d9410d8d0271132d2f8293480" +checksum = "f258a7194e7f7c2a7837a8913aeab7fd8c383457034fa20ce4dd3dcb813e8eb8" dependencies = [ - "errno-dragonfly", "libc", "windows-sys 0.48.0", ] -[[package]] -name = "errno-dragonfly" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" -dependencies = [ - "cc", - "libc", -] - [[package]] name = "error-code" version = "2.3.1" @@ -2065,6 +2352,27 @@ version = "2.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" +[[package]] +name = "event-listener" +version = "3.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d93877bcde0eb80ca09131a08d23f0a5c18a620b01db137dba666d18cd9b30c2" +dependencies = [ + "concurrent-queue", + "parking", + "pin-project-lite", +] + +[[package]] +name = "event-listener-strategy" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d96b852f1345da36d551b9473fa1e2b1eb5c5195585c6c018118bc92a8d91160" +dependencies = [ + "event-listener 3.1.0", + "pin-project-lite", +] + [[package]] name = "exr" version = "1.71.0" @@ -2098,9 +2406,9 @@ checksum = "25cbce373ec4653f1a01a31e8a5e5ec0c622dc27ff9c4e6606eefef5cbbed4a5" [[package]] name = "fdeflate" -version = "0.3.0" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d329bdeac514ee06249dabc27877490f17f5d371ec693360768b838e19f3ae10" +checksum = "64d6dafc854908ff5da46ff3f8f473c6984119a2876a383a860246dd7841a868" dependencies = [ "simd-adler32", ] @@ -2111,7 +2419,7 @@ version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5a3a2d0ff0df09856a5c1c89cc83863a1f0f994c55452186621bb57a01f270b3" dependencies = [ - "bitflags 2.4.0", + "bitflags 2.4.1", "fnv", "generational-arena", "glow", @@ -2150,9 +2458,9 @@ dependencies = [ [[package]] name = "flate2" -version = "1.0.27" +version = "1.0.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6c98ee8095e9d1dcbf2fcc6d95acccb90d1c81db1e44725c6a984b1dbdfb010" +checksum = "46303f565772937ffe1d394a4fac6f411c6013172fadde9dcdb1e147a086940e" dependencies = [ "crc32fast", "miniz_oxide", @@ -2170,7 +2478,7 @@ version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "55ac459de2512911e4b674ce33cf20befaba382d05b62b008afc1c8b57cbf181" dependencies = [ - "spin 0.9.8", + "spin", ] [[package]] @@ -2239,7 +2547,7 @@ checksum = "1a5c6c585bc94aaf2c7b51dd4c2ba22680844aba4c687be581871a6f518c5742" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -2275,24 +2583,24 @@ dependencies = [ [[package]] name = "futures-channel" -version = "0.3.28" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "955518d47e09b25bbebc7a18df10b81f0c766eaf4c4f1cccef2fca5f2a4fb5f2" +checksum = "ff4dd66668b557604244583e3e1e1eada8c5c2e96a6d0d6653ede395b78bbacb" dependencies = [ "futures-core", ] [[package]] name = "futures-core" -version = "0.3.28" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bca583b7e26f571124fe5b7561d49cb2868d79116cfa0eefce955557c6fee8c" +checksum = "eb1d22c66e66d9d72e1758f0bd7d4fd0bee04cad842ee34587d68c07e45d088c" [[package]] name = "futures-executor" -version = "0.3.28" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccecee823288125bd88b4d7f565c9e58e41858e47ab72e8ea2d64e93624386e0" +checksum = "0f4fb8693db0cf099eadcca0efe2a5a22e4550f98ed16aba6c48700da29597bc" dependencies = [ "futures-core", "futures-task", @@ -2301,9 +2609,9 @@ dependencies = [ [[package]] name = "futures-io" -version = "0.3.28" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fff74096e71ed47f8e023204cfd0aa1289cd54ae5430a9523be060cdb849964" +checksum = "8bf34a163b5c4c52d0478a4d757da8fb65cabef42ba90515efee0f6f9fa45aaa" [[package]] name = "futures-lite" @@ -2320,34 +2628,44 @@ dependencies = [ "waker-fn", ] +[[package]] +name = "futures-lite" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3831c2651acb5177cbd83943f3d9c8912c5ad03c76afcc0e9511ba568ec5ebb" +dependencies = [ + "futures-core", + "pin-project-lite", +] + [[package]] name = "futures-macro" -version = "0.3.28" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72" +checksum = "53b153fd91e4b0147f4aced87be237c98248656bb01050b96bf3ee89220a8ddb" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] name = "futures-sink" -version = "0.3.28" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f43be4fe21a13b9781a69afa4985b0f6ee0e1afab2c6f454a8cf30e2b2237b6e" +checksum = "e36d3378ee38c2a36ad710c5d30c2911d752cb941c00c72dbabfb786a7970817" [[package]] name = "futures-task" -version = "0.3.28" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76d3d132be6c0e6aa1534069c705a74a5997a356c0dc2f86a47765e5617c5b65" +checksum = "efd193069b0ddadc69c46389b740bbccdd97203899b48d09c5f7969591d6bae2" [[package]] name = "futures-util" -version = "0.3.28" +version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26b01e40b772d54cf6c6d721c1d1abd0647a0106a12ecaa1c186273392a69533" +checksum = "a19526d624e703a3179b3d322efec918b6246ea0fa51d41124525f00f1cc8104" dependencies = [ "futures-core", "futures-io", @@ -2542,9 +2860,9 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.2.10" +version = "0.2.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be4136b2a15dd319360be1c07d9933517ccf0be8f16bf62a3bee4f0d618df427" +checksum = "fe9006bed769170c11f845cf00c7c1e9092aeb3f268e007c3e760ac68008070f" dependencies = [ "cfg-if", "libc", @@ -2641,7 +2959,7 @@ checksum = "fb1a9325847aa46f1e96ffea37611b9d51fc4827e67f79e7de502a297560a67b" dependencies = [ "anyhow", "heck", - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro-error", "proc-macro2", "quote", @@ -2687,28 +3005,64 @@ dependencies = [ "cgl", "core-foundation", "dispatch", - "glutin_egl_sys", - "glutin_glx_sys", - "glutin_wgl_sys", + "glutin_egl_sys 0.5.1", + "glutin_glx_sys 0.4.0", + "glutin_wgl_sys 0.4.0", "libloading 0.7.4", - "objc2", + "objc2 0.3.0-beta.3.patch-leaks.3", "once_cell", - "raw-window-handle", + "raw-window-handle 0.5.2", "wayland-sys 0.30.1", "windows-sys 0.45.0", "x11-dl", ] +[[package]] +name = "glutin" +version = "0.31.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eca18d477e18c996c1fd1a50e04c6a745b67e2d512c7fb51f2757d9486a0e3ee" +dependencies = [ + "bitflags 2.4.1", + "cfg_aliases", + "cgl", + "core-foundation", + "dispatch", + "glutin_egl_sys 0.6.0", + "glutin_glx_sys 0.5.0", + "glutin_wgl_sys 0.5.0", + "icrate", + "libloading 0.8.1", + "objc2 0.4.1", + "once_cell", + "raw-window-handle 0.5.2", + "wayland-sys 0.31.1", + "windows-sys 0.48.0", + "x11-dl", +] + +[[package]] +name = "glutin-winit" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "629a873fc04062830bfe8f97c03773bcd7b371e23bcc465d0a61448cd1588fa4" +dependencies = [ + "cfg_aliases", + "glutin 0.30.10", + "raw-window-handle 0.5.2", + "winit 0.28.7", +] + [[package]] name = "glutin-winit" -version = "0.3.0" +version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "629a873fc04062830bfe8f97c03773bcd7b371e23bcc465d0a61448cd1588fa4" +checksum = "1ebcdfba24f73b8412c5181e56f092b5eff16671c514ce896b258a0a64bd7735" dependencies = [ "cfg_aliases", - "glutin", - "raw-window-handle", - "winit", + "glutin 0.31.1", + "raw-window-handle 0.5.2", + "winit 0.29.3", ] [[package]] @@ -2721,6 +3075,16 @@ dependencies = [ "windows-sys 0.45.0", ] +[[package]] +name = "glutin_egl_sys" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77cc5623f5309ef433c3dd4ca1223195347fe62c413da8e2fdd0eb76db2d9bcd" +dependencies = [ + "gl_generator", + "windows-sys 0.48.0", +] + [[package]] name = "glutin_glx_sys" version = "0.4.0" @@ -2731,6 +3095,16 @@ dependencies = [ "x11-dl", ] +[[package]] +name = "glutin_glx_sys" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a165fd686c10dcc2d45380b35796e577eacfd43d4660ee741ec8ebe2201b3b4f" +dependencies = [ + "gl_generator", + "x11-dl", +] + [[package]] name = "glutin_wgl_sys" version = "0.4.0" @@ -2740,6 +3114,15 @@ dependencies = [ "gl_generator", ] +[[package]] +name = "glutin_wgl_sys" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c8098adac955faa2d31079b65dc48841251f69efd3ac25477903fc424362ead" +dependencies = [ + "gl_generator", +] + [[package]] name = "gobject-sys" version = "0.16.3" @@ -2799,7 +3182,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "096eb63c6fedf03bafe65e5924595785eaf1bcb7200dac0f2cbe9c9738f05ad8" dependencies = [ "anyhow", - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro-error", "proc-macro2", "quote", @@ -2808,9 +3191,9 @@ dependencies = [ [[package]] name = "h2" -version = "0.3.21" +version = "0.3.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91fc23aa11be92976ef4729127f1a74adf36d8436f7816b185d18df956790833" +checksum = "4d6250322ef6e60f93f9a2162799302cd6f68f79f6e5d85c8c16f14d1d958178" dependencies = [ "bytes", "fnv", @@ -2818,7 +3201,7 @@ dependencies = [ "futures-sink", "futures-util", "http", - "indexmap 1.9.3", + "indexmap 2.1.0", "slab", "tokio", "tokio-util", @@ -2865,9 +3248,9 @@ dependencies = [ [[package]] name = "hashbrown" -version = "0.14.1" +version = "0.14.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dfda62a12f55daeae5015f81b0baea145391cb4520f86c248fc615d72640d12" +checksum = "f93e7192158dbcda357bdec5fb5788eebf8bbac027f3f33e719d29135ae84156" [[package]] name = "heck" @@ -2921,9 +3304,9 @@ dependencies = [ [[package]] name = "http" -version = "0.2.9" +version = "0.2.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" +checksum = "8947b1a6fad4393052c7ba1f4cd97bed3e953a95c79c92ad9b051a04611d9fbb" dependencies = [ "bytes", "fnv", @@ -2976,38 +3359,65 @@ dependencies = [ "httpdate", "itoa 1.0.9", "pin-project-lite", - "socket2 0.4.9", + "socket2 0.4.10", "tokio", "tower-service", "tracing", "want", ] +[[package]] +name = "hyper-rustls" +version = "0.24.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec3efd23720e2049821a693cbc7e65ea87c72f1c58ff2f9522ff332b1491e590" +dependencies = [ + "futures-util", + "http", + "hyper", + "rustls", + "tokio", + "tokio-rustls", +] + +[[package]] +name = "hyper-tls" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" +dependencies = [ + "bytes", + "hyper", + "native-tls", + "tokio", + "tokio-native-tls", +] + [[package]] name = "i-slint-backend-linuxkms" -version = "1.2.2" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e321d0f8d12509ec2ed5b5aba4996922606686ac3d86d70ba126cba1b4e4563" +checksum = "8955a5385270c9a8d76530e872a397eb6717bd1020f16c09c7f9c7fc1a59cd39" dependencies = [ "calloop 0.11.0", "drm", "gbm", - "glutin", + "glutin 0.31.1", "i-slint-common", "i-slint-core", "i-slint-renderer-femtovg", "input", "libseat", "nix 0.27.1", - "raw-window-handle", + "raw-window-handle 0.5.2", "xkbcommon", ] [[package]] name = "i-slint-backend-qt" -version = "1.2.2" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f1ce3687c329341842f79c31c95d7bcf49b6fda7fd19b09e0b5d7fb33b9d6b2" +checksum = "e3d1efb491728deba46aa6554c7589256f5e95f956237b55ab4d9cc098f3ec18" dependencies = [ "const-field-offset", "cpp", @@ -3025,25 +3435,26 @@ dependencies = [ [[package]] name = "i-slint-backend-selector" -version = "1.2.2" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7382cc01e9c9ef607debe1e4af7e1c6af78720a258fd18d8e32761b8593c5db" +checksum = "059bb78add36aaa9cc1a4f7e5978f47e5ec1ece31ca281451cc646ef3a7e4d85" dependencies = [ "cfg-if", "i-slint-backend-linuxkms", "i-slint-backend-qt", "i-slint-backend-winit", + "i-slint-common", "i-slint-core", ] [[package]] name = "i-slint-backend-winit" -version = "1.2.2" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8c0f3f01e2c678d24b81914a38e53d3b660a0ef13831acb59c71bd7c95ed0cb" +checksum = "8992e2356a2331502261987d2a6803e798bf7a2a5272907713c08f46a7ad0652" dependencies = [ - "accesskit", - "accesskit_winit", + "accesskit 0.12.1", + "accesskit_winit 0.16.1", "bytemuck", "cfg-if", "cfg_aliases", @@ -3051,19 +3462,18 @@ dependencies = [ "const-field-offset", "copypasta", "derive_more", - "glutin", - "glutin-winit", + "glutin 0.31.1", + "glutin-winit 0.4.2", "i-slint-common", "i-slint-core", "i-slint-core-macros", "i-slint-renderer-femtovg", "i-slint-renderer-skia", "imgref", - "instant", "lyon_path", "once_cell", "pin-weak", - "raw-window-handle", + "raw-window-handle 0.5.2", "rgb", "scoped-tls-hkt", "scopeguard", @@ -3072,14 +3482,14 @@ dependencies = [ "vtable", "wasm-bindgen", "web-sys", - "winit", + "winit 0.29.3", ] [[package]] name = "i-slint-common" -version = "1.2.2" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7daf484e68bf27e06b7501767c6e66063c0f85948e57a6de679b53d2d9d2044" +checksum = "181a597710932e4ba09cd29fed3d479587fe33d3c880b0addd5421dbed4940bd" dependencies = [ "cfg-if", "derive_more", @@ -3089,16 +3499,15 @@ dependencies = [ [[package]] name = "i-slint-compiler" -version = "1.2.2" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b99172cc43ca17a78e96e3f8f13699d9fc1c00474d2d87bc57c0f7e816c4a48" +checksum = "0020485613a80b6dfe86a46f93c946b8382045ccbb29f7b9faf20725658fc7f0" dependencies = [ "by_address", "codemap", "codemap-diagnostic", "css-color-parser2", "derive_more", - "dunce", "fontdue", "i-slint-common", "image", @@ -3106,7 +3515,7 @@ dependencies = [ "linked_hash_set", "lyon_extra", "lyon_path", - "num_enum 0.7.0", + "num_enum 0.7.1", "once_cell", "proc-macro2", "quote", @@ -3120,9 +3529,9 @@ dependencies = [ [[package]] name = "i-slint-core" -version = "1.2.2" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b62e590bb3d6009447a52760e9343c25a3bf7a8a7b0ad7ab5a77c5324fcaa957" +checksum = "408aa4fe8a28ae7284d18d0b35612fe172c096392dc429342e3626926c70e595" dependencies = [ "auto_enums", "bytemuck", @@ -3135,7 +3544,6 @@ dependencies = [ "i-slint-common", "i-slint-core-macros", "image", - "instant", "integer-sqrt", "lyon_algorithms", "lyon_extra", @@ -3160,23 +3568,24 @@ dependencies = [ "vtable", "wasm-bindgen", "web-sys", + "web-time", ] [[package]] name = "i-slint-core-macros" -version = "1.2.2" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62a416f1e9fc42c2bf1f171e5be38a8155850fcd390fce300869bcc9d6c9c117" +checksum = "c8d582a1644a5d818ee813f393490a5b2496936ef3962b62ff077e42a81626ef" dependencies = [ "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] name = "i-slint-renderer-femtovg" -version = "1.2.2" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e99a941fca00b96a7756d56e4bc5e2876283f34c693eabc73585c0b91ab84f0" +checksum = "fbc056f6daab6224bb55a55751456ab2897a41ade84ca7772001a1cff46a6b26" dependencies = [ "cfg-if", "const-field-offset", @@ -3190,11 +3599,10 @@ dependencies = [ "i-slint-core", "i-slint-core-macros", "imgref", - "instant", "lyon_path", "once_cell", "pin-weak", - "raw-window-handle", + "raw-window-handle 0.5.2", "rgb", "scoped-tls-hkt", "ttf-parser 0.18.1", @@ -3208,10 +3616,11 @@ dependencies = [ [[package]] name = "i-slint-renderer-skia" -version = "1.2.2" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f617268cfee53e1fa3fcab8f6ab2775deacfce74057386c4ad39ef2647f8db6" +checksum = "82c4893627aa07956397bc997b4bcb83a22e1b364f8109be72505168837e2eb7" dependencies = [ + "bytemuck", "cfg-if", "cfg_aliases", "cocoa 0.24.1", @@ -3221,38 +3630,37 @@ dependencies = [ "derive_more", "foreign-types 0.3.2", "glow", - "glutin", + "glutin 0.31.1", "i-slint-common", "i-slint-core", "i-slint-core-macros", - "instant", "lyon_path", "metal", "objc", "once_cell", "pin-weak", - "raw-window-handle", + "raw-window-handle 0.5.2", "scoped-tls-hkt", "skia-safe", + "softbuffer", "unicode-segmentation", "vtable", "winapi", - "winit", "wio", ] [[package]] name = "iana-time-zone" -version = "0.1.57" +version = "0.1.58" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fad5b825842d2b38bd206f3e81d6957625fd7f0a361e345c30e01a0ae2dd613" +checksum = "8326b86b6cff230b97d0d312a6c40a60726df3332e721f72a1b035f451663b20" dependencies = [ "android_system_properties", "core-foundation-sys", "iana-time-zone-haiku", "js-sys", "wasm-bindgen", - "windows 0.48.0", + "windows-core", ] [[package]] @@ -3274,6 +3682,17 @@ dependencies = [ "png", ] +[[package]] +name = "icrate" +version = "0.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99d3aaff8a54577104bafdf686ff18565c3b6903ca5782a2026ef06e2c7aa319" +dependencies = [ + "block2 0.3.0", + "dispatch", + "objc2 0.4.1", +] + [[package]] name = "ident_case" version = "1.0.1" @@ -3317,9 +3736,9 @@ checksum = "029d73f573d8e8d63e6d5020011d3255b28c3ba85d6cf870a07184ed23de9284" [[package]] name = "imgref" -version = "1.9.4" +version = "1.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2cf49df1085dcfb171460e4592597b84abe50d900fb83efb6e41b20fefd6c2c" +checksum = "90d944e334f00f4449c9640b440a171f816be0152305c12ef90424fc35fd035c" [[package]] name = "indexmap" @@ -3334,12 +3753,12 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.0.2" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8adf3ddd720272c6ea8bf59463c04e0f93d0bbf7c5439b691bca2987e0270897" +checksum = "d530e1a18b1cb4c484e6e34556a0d948706958449fca0cab753d649f2bce3d1f" dependencies = [ "equivalent", - "hashbrown 0.14.1", + "hashbrown 0.14.2", "serde", ] @@ -3453,9 +3872,9 @@ dependencies = [ [[package]] name = "ipnet" -version = "2.8.0" +version = "2.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28b29a3cd74f0f4598934efe3aeba42bae0eb4680554128851ebbecb02af14e6" +checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" [[package]] name = "itertools" @@ -3539,9 +3958,9 @@ checksum = "8eaf4bc02d17cbdd7ff4c7438cafcdf7fb9a4613313ad11b4f8fefe7d3fa0130" [[package]] name = "jobserver" -version = "0.1.26" +version = "0.1.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "936cfd212a0155903bcbc060e316fb6cc7cbf2e1907329391ebadc1fe0ce77c2" +checksum = "8c37f63953c4c63420ed5fd3d6d398c719489b9f872b9fa683262f8edd363c7d" dependencies = [ "libc", ] @@ -3557,18 +3976,18 @@ dependencies = [ [[package]] name = "js-sys" -version = "0.3.64" +version = "0.3.65" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c5f195fe497f702db0f318b07fdd68edb16955aed830df8363d837542f8f935a" +checksum = "54c0c35952f67de54bb584e9fd912b3023117cbafc0a77d8f3dee1fb5f572fe8" dependencies = [ "wasm-bindgen", ] [[package]] name = "json-patch" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f7765dccf8c39c3a470fc694efe322969d791e713ca46bc7b5c506886157572" +checksum = "55ff1e1486799e3f64129f8ccad108b38290df9cd7015cd31bed17239f0789d6" dependencies = [ "serde", "serde_json", @@ -3640,9 +4059,9 @@ checksum = "03087c2bad5e1034e8cace5926dec053fb3790248370865f5117a7d0213354c8" [[package]] name = "libc" -version = "0.2.148" +version = "0.2.150" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cdc71e17332e86d2e1d38c1f99edcb6288ee11b815fb1a4b049eaa2114d369b" +checksum = "89d92a4743f9a61002fae18374ed11e7973f530cb3a3255fb354818118b2203c" [[package]] name = "libflate" @@ -3690,9 +4109,31 @@ dependencies = [ [[package]] name = "libm" -version = "0.2.7" +version = "0.2.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" + +[[package]] +name = "libredox" +version = "0.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85c833ca1e66078851dba29046874e38f08b2c883700aa29a03ddd3b23814ee8" +dependencies = [ + "bitflags 2.4.1", + "libc", + "redox_syscall 0.4.1", +] + +[[package]] +name = "libredox" +version = "0.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7012b1bbb0719e1097c47611d3898568c546d597c2e74d66f6087edd5233ff4" +checksum = "3af92c55d7d839293953fcd0fda5ecfe93297cfde6ffbdec13b41d99c0ba6607" +dependencies = [ + "bitflags 2.4.1", + "libc", + "redox_syscall 0.4.1", +] [[package]] name = "libseat" @@ -3700,11 +4141,9 @@ version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "54a0adf8d8607a73a5b74cbe4132f57cb349e4bf860103cd089461bbcbc9907e" dependencies = [ - "cc", "errno", "libseat-sys", "log", - "pkg-config", ] [[package]] @@ -3758,15 +4197,15 @@ checksum = "ef53942eb7bf7ff43a617b3e2c1c4a5ecf5944a7c1bc12d7ee39bbb15e5c1519" [[package]] name = "linux-raw-sys" -version = "0.4.8" +version = "0.4.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3852614a3bd9ca9804678ba6be5e3b8ce76dfc902cae004e3e0c44051b6e88db" +checksum = "969488b55f8ac402214f3f5fd243ebb7206cf82de60d3172994707a4bcc2b829" [[package]] name = "lock_api" -version = "0.4.10" +version = "0.4.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1cc9717a20b1bb222f333e6a92fd32f7d8a18ddc5a3191a11af45dcbf4dcd16" +checksum = "3c168f8615b12bc01f9c17e2eb0cc07dcae1940121185446edc3744920e8ef45" dependencies = [ "autocfg", "scopeguard", @@ -3928,6 +4367,15 @@ dependencies = [ "libc", ] +[[package]] +name = "memmap2" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "deaba38d7abf1d4cca21cc89e932e542ba2b9258664d2a9ef0e61512039c9375" +dependencies = [ + "libc", +] + [[package]] name = "memoffset" version = "0.6.5" @@ -3987,11 +4435,17 @@ version = "0.7.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d2b6f58413c6cee060115673578e47271838f3c87cb9322c61a3bcd6d740b7d2" dependencies = [ - "getrandom 0.2.10", + "getrandom 0.2.11", "rpassword", "scrypt", ] +[[package]] +name = "minisign-verify" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "933dca44d65cdd53b355d0b73d380a2ff5da71f87f036053188bf1eab6a19881" + [[package]] name = "miniz_oxide" version = "0.7.1" @@ -4004,9 +4458,9 @@ dependencies = [ [[package]] name = "mio" -version = "0.8.8" +version = "0.8.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "927a765cd3fc26206e66b296465fa9d3e5ab003e651c1b3c060e7956d96b19d2" +checksum = "3dce281c5e46beae905d4de1870d8b1509a9142b62eedf18b443b011ca8343d0" dependencies = [ "libc", "log", @@ -4020,7 +4474,7 @@ version = "2.14.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1133249c46e92da921bafc8aba4912bf84d6c475f7625183772ed2d0844dc3a7" dependencies = [ - "bitflags 2.4.0", + "bitflags 2.4.1", "ctor 0.2.5", "napi-derive", "napi-sys", @@ -4112,7 +4566,23 @@ dependencies = [ "jni-sys", "ndk-sys 0.4.1+23.1.7779620", "num_enum 0.5.11", - "raw-window-handle", + "raw-window-handle 0.5.2", + "thiserror", +] + +[[package]] +name = "ndk" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2076a31b7010b17a38c01907c45b945e8f11495ee4dd588309718901b1f7a5b7" +dependencies = [ + "bitflags 2.4.1", + "jni-sys", + "log", + "ndk-sys 0.5.0+25.2.9519653", + "num_enum 0.7.1", + "raw-window-handle 0.5.2", + "raw-window-handle 0.6.0", "thiserror", ] @@ -4140,6 +4610,15 @@ dependencies = [ "jni-sys", ] +[[package]] +name = "ndk-sys" +version = "0.5.0+25.2.9519653" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8c196769dd60fd4f363e11d948139556a344e79d451aeb2fa2fd040738ef7691" +dependencies = [ + "jni-sys", +] + [[package]] name = "new_debug_unreachable" version = "1.0.4" @@ -4181,7 +4660,6 @@ dependencies = [ "cfg-if", "libc", "memoffset 0.7.1", - "pin-utils", ] [[package]] @@ -4190,7 +4668,7 @@ version = "0.27.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2eb04e9c688eff1c89d72b407f168cf79bb9e867a9d3323ed6c01519eb9cc053" dependencies = [ - "bitflags 2.4.0", + "bitflags 2.4.1", "cfg-if", "libc", ] @@ -4250,9 +4728,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.16" +version = "0.2.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f30b0abd723be7e2ffca1272140fac1a2f084c77ec3e123c192b66af1ee9e6c2" +checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" dependencies = [ "autocfg", "libm", @@ -4288,11 +4766,11 @@ dependencies = [ [[package]] name = "num_enum" -version = "0.7.0" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70bf6736f74634d299d00086f02986875b3c2d924781a6a2cb6c201e73da0ceb" +checksum = "683751d591e6d81200c39fb0d1032608b77724f34114db54f571ff1317b337c0" dependencies = [ - "num_enum_derive 0.7.0", + "num_enum_derive 0.7.1", ] [[package]] @@ -4301,7 +4779,7 @@ version = "0.5.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dcbff9bc912032c62bf65ef1d5aea88983b420f4f839db1e9b0c281a25c9c799" dependencies = [ - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", "syn 1.0.109", @@ -4313,22 +4791,22 @@ version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "96667db765a921f7b295ffee8b60472b686a51d4f21c2ee4ffdb94c7013b65a6" dependencies = [ - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] name = "num_enum_derive" -version = "0.7.0" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56ea360eafe1022f7cc56cd7b869ed57330fb2453d0c7831d99b74c65d2f5597" +checksum = "6c11e44798ad209ccdd91fc192f0526a369a01234f7373e1b141c96d7cee4f0e" dependencies = [ - "proc-macro-crate", + "proc-macro-crate 2.0.0", "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -4358,15 +4836,31 @@ version = "0.2.0-beta.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "df3b9834c1e95694a05a828b59f55fa2afec6288359cda67146126b3f90a55d7" +[[package]] +name = "objc-sys" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99e1d07c6eab1ce8b6382b8e3c7246fe117ff3f8b34be065f5ebace6749fe845" + [[package]] name = "objc2" version = "0.3.0-beta.3.patch-leaks.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7e01640f9f2cb1220bbe80325e179e532cb3379ebcd1bf2279d703c19fe3a468" dependencies = [ - "block2", - "objc-sys", - "objc2-encode", + "block2 0.2.0-alpha.6", + "objc-sys 0.2.0-beta.2", + "objc2-encode 2.0.0-pre.2", +] + +[[package]] +name = "objc2" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "559c5a40fdd30eb5e344fbceacf7595a81e242529fb4e21cf5f43fb4f11ff98d" +dependencies = [ + "objc-sys 0.3.1", + "objc2-encode 3.0.0", ] [[package]] @@ -4375,9 +4869,15 @@ version = "2.0.0-pre.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "abfcac41015b00a120608fdaa6938c44cb983fee294351cc4bac7638b4e50512" dependencies = [ - "objc-sys", + "objc-sys 0.2.0-beta.2", ] +[[package]] +name = "objc2-encode" +version = "3.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d079845b37af429bfe5dfa76e6d087d788031045b25cfc6fd898486fd9847666" + [[package]] name = "objc_exception" version = "0.1.2" @@ -4421,7 +4921,7 @@ version = "0.10.59" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7a257ad03cd8fb16ad4172fedf8094451e1af1c4b70097636ef2eac9a5f0cc33" dependencies = [ - "bitflags 2.4.0", + "bitflags 2.4.1", "cfg-if", "foreign-types 0.3.2", "libc", @@ -4438,7 +4938,7 @@ checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -4477,18 +4977,18 @@ checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" [[package]] name = "orbclient" -version = "0.3.46" +version = "0.3.47" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8378ac0dfbd4e7895f2d2c1f1345cab3836910baf3a300b000d04250f0c8428f" +checksum = "52f0d54bde9774d3a51dcf281a5def240c71996bc6ca05d2c847ec8b2b216166" dependencies = [ - "redox_syscall 0.3.5", + "libredox 0.0.2", ] [[package]] name = "ordered-float" -version = "2.10.0" +version = "2.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7940cf2ca942593318d07fcf2596cdca60a85c9e7fab408a5e21a4f9dcd40d87" +checksum = "68f19d67e5a2795c94e73e0bb1cc1a7edeb2e28efd39e2e1c9b7a40c1108b11c" dependencies = [ "num-traits", ] @@ -4521,11 +5021,11 @@ checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" [[package]] name = "owned_ttf_parser" -version = "0.19.0" +version = "0.20.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "706de7e2214113d63a8238d1910463cfce781129a6f263d13fdb09ff64355ba4" +checksum = "d4586edfe4c648c71797a74c84bacb32b52b212eff5dfe2bb9f2c599844023e7" dependencies = [ - "ttf-parser 0.19.2", + "ttf-parser 0.20.0", ] [[package]] @@ -4556,9 +5056,9 @@ dependencies = [ [[package]] name = "parking" -version = "2.1.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e52c774a4c39359c1d1c52e43f73dd91a75a614652c825408eec30c95a9b2067" +checksum = "bb813b8af86854136c6922af0598d719255ecb2179515e6e7730d468f05c9cae" [[package]] name = "parking_lot" @@ -4572,13 +5072,13 @@ dependencies = [ [[package]] name = "parking_lot_core" -version = "0.9.8" +version = "0.9.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f00c865fe7cabf650081affecd3871070f26767e7b2070a3ffae14c654b447" +checksum = "4c42a9226546d68acdd9c0a280d17ce19bfe27a46bf68784e4066115788d008e" dependencies = [ "cfg-if", "libc", - "redox_syscall 0.3.5", + "redox_syscall 0.4.1", "smallvec", "windows-targets 0.48.5", ] @@ -4613,9 +5113,9 @@ checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94" [[package]] name = "pest" -version = "2.7.4" +version = "2.7.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c022f1e7b65d6a24c0dbbd5fb344c66881bc01f3e5ae74a1c8100f2f985d98a4" +checksum = "ae9cee2a55a544be8b89dc6848072af97a20f2422603c10865be2a42b580fff5" dependencies = [ "memchr", "thiserror", @@ -4624,9 +5124,9 @@ dependencies = [ [[package]] name = "pest_derive" -version = "2.7.4" +version = "2.7.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35513f630d46400a977c4cb58f78e1bfbe01434316e60c37d27b9ad6139c66d8" +checksum = "81d78524685f5ef2a3b3bd1cafbc9fcabb036253d9b1463e726a91cd16e2dfc2" dependencies = [ "pest", "pest_generator", @@ -4634,22 +5134,22 @@ dependencies = [ [[package]] name = "pest_generator" -version = "2.7.4" +version = "2.7.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc9fc1b9e7057baba189b5c626e2d6f40681ae5b6eb064dc7c7834101ec8123a" +checksum = "68bd1206e71118b5356dae5ddc61c8b11e28b09ef6a31acbd15ea48a28e0c227" dependencies = [ "pest", "pest_meta", "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] name = "pest_meta" -version = "2.7.4" +version = "2.7.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1df74e9e7ec4053ceb980e7c0c8bd3594e977fde1af91daba9c928e8e8c6708d" +checksum = "7c747191d4ad9e4a4ab9c8798f1e82a39affe7ef9648390b7e5548d18e099de6" dependencies = [ "once_cell", "pest", @@ -4777,7 +5277,7 @@ checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -4817,14 +5317,14 @@ checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" [[package]] name = "plist" -version = "1.5.0" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bdc0001cfea3db57a2e24bc0d818e9e20e554b5f97fabb9bc231dc240269ae06" +checksum = "e5699cc8a63d1aa2b1ee8e12b9ad70ac790d65788cd36101fa37f87ea46c4cef" dependencies = [ - "base64 0.21.4", - "indexmap 1.9.3", + "base64 0.21.5", + "indexmap 2.1.0", "line-wrap", - "quick-xml 0.29.0", + "quick-xml 0.31.0", "serde", "time", ] @@ -4858,15 +5358,35 @@ dependencies = [ "windows-sys 0.48.0", ] +[[package]] +name = "polling" +version = "3.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e53b6af1f60f36f8c2ac2aad5459d75a5a9b4be1e8cdd40264f315d78193e531" +dependencies = [ + "cfg-if", + "concurrent-queue", + "pin-project-lite", + "rustix 0.38.24", + "tracing", + "windows-sys 0.48.0", +] + [[package]] name = "portable-atomic" -version = "1.4.3" +version = "1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31114a898e107c51bb1609ffaf55a0e011cf6a4d7f1170d0015a165082c0338b" +checksum = "3bccab0e7fd7cc19f820a1c8c91720af652d0c88dc9664dd72aef2614f04af3b" dependencies = [ "critical-section", ] +[[package]] +name = "powerfmt" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391" + [[package]] name = "ppv-lite86" version = "0.2.17" @@ -4886,7 +5406,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ae005bd773ab59b4725093fd7df83fd7892f7d8eafb48dbd7de6e024e4215f9d" dependencies = [ "proc-macro2", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -4899,6 +5419,15 @@ dependencies = [ "toml_edit 0.19.15", ] +[[package]] +name = "proc-macro-crate" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7e8366a6159044a37876a2b9817124296703c586a5c92e2c53751fa06d8d43e8" +dependencies = [ + "toml_edit 0.20.7", +] + [[package]] name = "proc-macro-error" version = "1.0.4" @@ -4931,9 +5460,9 @@ checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068" [[package]] name = "proc-macro2" -version = "1.0.67" +version = "1.0.69" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d433d9f1a3e8c1263d9456598b16fec66f4acc9a74dacffd35c7bb09b3a1328" +checksum = "134c189feb4956b20f6f547d2cf727d4c0fe06722b20a0eec87ed445a97f92da" dependencies = [ "unicode-ident", ] @@ -4949,9 +5478,9 @@ dependencies = [ [[package]] name = "qttypes" -version = "0.2.9" +version = "0.2.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "116e96ef85a287acd172c5ed017ef56ee1d9e4f016558e8fc1625925f3f77468" +checksum = "d405b0934e4176fb264d6ca597e5c8c2fba562fa155cba681ca160c1eb7edc6e" dependencies = [ "cpp", "cpp_build", @@ -4960,18 +5489,18 @@ dependencies = [ [[package]] name = "quick-xml" -version = "0.28.2" +version = "0.30.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ce5e73202a820a31f8a0ee32ada5e21029c81fd9e3ebf668a40832e4219d9d1" +checksum = "eff6510e86862b57b210fd8cbe8ed3f0d7d600b9c2863cd4549a2e033c66e956" dependencies = [ "memchr", ] [[package]] name = "quick-xml" -version = "0.29.0" +version = "0.31.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81b9228215d82c7b61490fec1de287136b5de6f5700f6e58ea9ad61a7964ca51" +checksum = "1004a344b30a54e2ee58d66a71b32d2db2feb0a31f9a2d302bf0536f15de2a33" dependencies = [ "memchr", ] @@ -5045,7 +5574,7 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" dependencies = [ - "getrandom 0.2.10", + "getrandom 0.2.11", ] [[package]] @@ -5072,6 +5601,12 @@ version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f2ff9a1f06a88b01621b7ae906ef0211290d1c8a168a15542486a8f61c0833b9" +[[package]] +name = "raw-window-handle" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42a9830a0e1b9fb145ebb365b8bc4ccd75f290f98c0247deafbbe2c75cefb544" + [[package]] name = "rayon" version = "1.8.0" @@ -5100,43 +5635,43 @@ checksum = "3b42e27ef78c35d3998403c1d26f3efd9e135d3e5121b0a4845cc5cc27547f4f" [[package]] name = "redox_syscall" -version = "0.2.16" +version = "0.3.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" +checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" dependencies = [ "bitflags 1.3.2", ] [[package]] name = "redox_syscall" -version = "0.3.5" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" +checksum = "4722d768eff46b75989dd134e5c353f0d6296e5aaa3132e776cbdb56be7731aa" dependencies = [ "bitflags 1.3.2", ] [[package]] name = "redox_users" -version = "0.4.3" +version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" +checksum = "a18479200779601e498ada4e8c1e1f50e3ee19deb0259c25825a98b5603b2cb4" dependencies = [ - "getrandom 0.2.10", - "redox_syscall 0.2.16", + "getrandom 0.2.11", + "libredox 0.0.1", "thiserror", ] [[package]] name = "regex" -version = "1.10.0" +version = "1.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d119d7c7ca818f8a53c300863d4f87566aac09943aef5b355bb83969dae75d87" +checksum = "380b951a9c5e80ddfd6136919eef32310721aa4aacd4889a8d39124b026ab343" dependencies = [ "aho-corasick", "memchr", - "regex-automata 0.4.0", - "regex-syntax 0.8.0", + "regex-automata 0.4.3", + "regex-syntax 0.8.2", ] [[package]] @@ -5150,13 +5685,13 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.0" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d58da636bd923eae52b7e9120271cbefb16f399069ee566ca5ebf9c30e32238" +checksum = "5f804c7828047e88b2d32e2d7fe5a105da8ee3264f01902f796c8e067dc2483f" dependencies = [ "aho-corasick", "memchr", - "regex-syntax 0.8.0", + "regex-syntax 0.8.2", ] [[package]] @@ -5167,9 +5702,9 @@ checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" [[package]] name = "regex-syntax" -version = "0.8.0" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3cbb081b9784b07cceb8824c8583f86db4814d172ab043f3c23f7dc600bf83d" +checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f" [[package]] name = "relative-path" @@ -5183,7 +5718,7 @@ version = "0.11.22" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "046cd98826c46c2ac8ddecae268eb5c2e58628688a5fc7a2643704a73faba95b" dependencies = [ - "base64 0.21.4", + "base64 0.21.5", "bytes", "encoding_rs", "futures-core", @@ -5192,18 +5727,25 @@ dependencies = [ "http", "http-body", "hyper", + "hyper-rustls", + "hyper-tls", "ipnet", "js-sys", "log", "mime", + "native-tls", "once_cell", "percent-encoding", "pin-project-lite", + "rustls", + "rustls-pemfile", "serde", "serde_json", "serde_urlencoded", "system-configuration", "tokio", + "tokio-native-tls", + "tokio-rustls", "tokio-util", "tower-service", "url", @@ -5211,6 +5753,7 @@ dependencies = [ "wasm-bindgen-futures", "wasm-streams", "web-sys", + "webpki-roots", "winreg 0.50.0", ] @@ -5234,7 +5777,7 @@ version = "0.11.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4fe664af397d2b6a13a8ba1d172a2b5c87c6c5149039edbf8fa122b98c9ed96f" dependencies = [ - "async-io", + "async-io 1.13.0", "block", "dispatch", "futures-util", @@ -5246,7 +5789,7 @@ dependencies = [ "objc", "objc-foundation", "objc_id", - "raw-window-handle", + "raw-window-handle 0.5.2", "wasm-bindgen", "wasm-bindgen-futures", "web-sys", @@ -5255,26 +5798,25 @@ dependencies = [ [[package]] name = "rgb" -version = "0.8.36" +version = "0.8.37" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20ec2d3e3fc7a92ced357df9cebd5a10b6fb2aa1ee797bf7e9ce2f17dffc8f59" +checksum = "05aaa8004b64fd573fc9d002f4e632d51ad4f026c2b5ba95fcb6c2f32c2c47d8" dependencies = [ "bytemuck", ] [[package]] name = "ring" -version = "0.16.20" +version = "0.17.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3053cf52e236a3ed746dfc745aa9cacf1b791d846bdaf412f60a8d7d6e17c8fc" +checksum = "fb0205304757e5d899b9c2e448b867ffd03ae7f988002e47cd24954391394d0b" dependencies = [ "cc", + "getrandom 0.2.11", "libc", - "once_cell", - "spin 0.5.2", + "spin", "untrusted", - "web-sys", - "winapi", + "windows-sys 0.48.0", ] [[package]] @@ -5307,23 +5849,23 @@ dependencies = [ [[package]] name = "rpassword" -version = "7.2.0" +version = "7.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6678cf63ab3491898c0d021b493c94c9b221d91295294a2a5746eacbe5928322" +checksum = "80472be3c897911d0137b2d2b9055faf6eeac5b14e324073d83bc17b191d7e3f" dependencies = [ "libc", "rtoolbox", - "winapi", + "windows-sys 0.48.0", ] [[package]] name = "rtoolbox" -version = "0.0.1" +version = "0.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "034e22c514f5c0cb8a10ff341b9b048b5ceb21591f31c8f44c43b960f9b3524a" +checksum = "c247d24e63230cdb56463ae328478bd5eac8b8faa8c69461a77e8e323afac90e" dependencies = [ "libc", - "winapi", + "windows-sys 0.48.0", ] [[package]] @@ -5349,9 +5891,9 @@ dependencies = [ [[package]] name = "rustix" -version = "0.37.24" +version = "0.37.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4279d76516df406a8bd37e7dff53fd37d1a093f997a3c34a5c21658c126db06d" +checksum = "fea8ca367a3a01fe35e6943c400addf443c0f57670e6ec51196f71a4b8762dd2" dependencies = [ "bitflags 1.3.2", "errno", @@ -5363,22 +5905,22 @@ dependencies = [ [[package]] name = "rustix" -version = "0.38.17" +version = "0.38.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f25469e9ae0f3d0047ca8b93fc56843f38e6774f0914a107ff8b41be8be8e0b7" +checksum = "9ad981d6c340a49cdc40a1028d9c6084ec7e9fa33fcb839cab656a267071e234" dependencies = [ - "bitflags 2.4.0", + "bitflags 2.4.1", "errno", "libc", - "linux-raw-sys 0.4.8", + "linux-raw-sys 0.4.11", "windows-sys 0.48.0", ] [[package]] name = "rustls" -version = "0.21.7" +version = "0.21.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd8d6c9f025a446bc4d18ad9632e69aec8f287aa84499ee335599fabd20c3fd8" +checksum = "629648aced5775d558af50b2b4c7b02983a04b312126d45eeead26e7caa498b9" dependencies = [ "log", "ring", @@ -5386,11 +5928,20 @@ dependencies = [ "sct", ] +[[package]] +name = "rustls-pemfile" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1c74cae0a4cf6ccbbf5f359f08efdf8ee7e1dc532573bf0db71968cb56b1448c" +dependencies = [ + "base64 0.21.5", +] + [[package]] name = "rustls-webpki" -version = "0.101.6" +version = "0.101.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c7d5dece342910d9ba34d259310cae3e0154b873b35408b787b59bce53d34fe" +checksum = "8b6275d1ee7a1cd780b64aca7726599a1dbc893b1e64144529e55c3c2f745765" dependencies = [ "ring", "untrusted", @@ -5459,9 +6010,9 @@ dependencies = [ [[package]] name = "schemars" -version = "0.8.15" +version = "0.8.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f7b0ce13155372a76ee2e1c5ffba1fe61ede73fbea5630d61eee6fac4929c0c" +checksum = "45a28f4c49489add4ce10783f7911893516f15afe45d015608d41faca6bc4d29" dependencies = [ "dyn-clone", "indexmap 1.9.3", @@ -5473,9 +6024,9 @@ dependencies = [ [[package]] name = "schemars_derive" -version = "0.8.15" +version = "0.8.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e85e2a16b12bdb763244c69ab79363d71db2b4b918a2def53f80b02e0574b13c" +checksum = "c767fd6fa65d9ccf9cf026122c1b555f2ef9a4f0cea69da4d7dbc3e258d30967" dependencies = [ "proc-macro2", "quote", @@ -5514,9 +6065,9 @@ dependencies = [ [[package]] name = "sct" -version = "0.7.0" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d53dcdb7c9f8158937a7981b48accfd39a43af418591a5d008c7b22b5e1b7ca4" +checksum = "da046153aa2352493d6cb7da4b6e5c0c057d8a1d0a9aa8560baffdd945acd414" dependencies = [ "ring", "untrusted", @@ -5531,10 +6082,23 @@ dependencies = [ "ab_glyph", "log", "memmap2 0.5.10", - "smithay-client-toolkit", + "smithay-client-toolkit 0.16.1", "tiny-skia 0.8.4", ] +[[package]] +name = "sctk-adwaita" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1729a30a469de249c6effc17ec8d039b0aa29b3af79b819b7f51cb6ab8046a90" +dependencies = [ + "ab_glyph", + "log", + "memmap2 0.9.0", + "smithay-client-toolkit 0.18.0", + "tiny-skia 0.11.2", +] + [[package]] name = "security-framework" version = "2.9.2" @@ -5580,9 +6144,9 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.19" +version = "1.0.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad977052201c6de01a8ef2aa3378c4bd23217a056337d1d6da40468d267a4fb0" +checksum = "836fa6a3e1e547f9a2c4040802ec865b5d85f4014efe00555d7090a3dcaa1090" dependencies = [ "serde", ] @@ -5595,9 +6159,9 @@ checksum = "cd0b0ec5f1c1ca621c432a25813d8d60c88abe6d3e08a3eb9cf37d97a0fe3d73" [[package]] name = "serde" -version = "1.0.188" +version = "1.0.192" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf9e0fcba69a370eed61bcf2b728575f726b50b55cba78064753d708ddc7549e" +checksum = "bca2a08484b285dcb282d0f67b26cadc0df8b19f8c12502c13d966bf9482f001" dependencies = [ "serde_derive", ] @@ -5614,13 +6178,13 @@ dependencies = [ [[package]] name = "serde_derive" -version = "1.0.188" +version = "1.0.192" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4eca7ac642d82aa35b60049a6eccb4be6be75e599bd2e9adb5f875a737654af2" +checksum = "d6c7207fbec9faa48073f3e3074cbe553af6ea512d7c21ba46e434e70ea9fbc1" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -5636,9 +6200,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.107" +version = "1.0.108" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b420ce6e3d8bd882e9b243c6eed35dbc9a6110c9769e74b584e0d68d1f20c65" +checksum = "3d1c7e3eac408d115102c4c24ad393e0821bb3a5df4d506a80f85f7a742a526b" dependencies = [ "itoa 1.0.9", "ryu", @@ -5647,20 +6211,20 @@ dependencies = [ [[package]] name = "serde_repr" -version = "0.1.16" +version = "0.1.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8725e1dfadb3a50f7e5ce0b1a540466f6ed3fe7a0fca2ac2b8b831d31316bd00" +checksum = "3081f5ffbb02284dda55132aa26daecedd7372a42417bbbab6f14ab7d6bb9145" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] name = "serde_spanned" -version = "0.6.3" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96426c9936fd7a0124915f9185ea1d20aa9445cc9821142f0a73bc9207a2e186" +checksum = "12022b835073e5b11e90a14f86838ceb1c8fb0325b72416845c487ac0fa95e80" dependencies = [ "serde", ] @@ -5679,15 +6243,15 @@ dependencies = [ [[package]] name = "serde_with" -version = "3.3.0" +version = "3.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ca3b16a3d82c4088f343b7480a93550b3eabe1a358569c2dfe38bbcead07237" +checksum = "64cd236ccc1b7a29e7e2739f27c0b2dd199804abc4290e32f59f3b68d6405c23" dependencies = [ - "base64 0.21.4", + "base64 0.21.5", "chrono", "hex", "indexmap 1.9.3", - "indexmap 2.0.2", + "indexmap 2.1.0", "serde", "serde_json", "serde_with_macros", @@ -5696,14 +6260,14 @@ dependencies = [ [[package]] name = "serde_with_macros" -version = "3.3.0" +version = "3.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e6be15c453eb305019bfa438b1593c731f36a289a7853f7707ee29e870b3b3c" +checksum = "93634eb5f75a2323b16de4748022ac4297f9e76b6dced2be287a099f41b5e788" dependencies = [ "darling", "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -5781,16 +6345,6 @@ version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a7cee0529a6d40f580e7a5e6c495c8fbfe21b7b52795ed4bb5e62cdf92bc6380" -[[package]] -name = "signal-hook" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8621587d4798caf8eb44879d42e56b9a93ea5dcd315a6487c357130095b62801" -dependencies = [ - "libc", - "signal-hook-registry", -] - [[package]] name = "signal-hook-registry" version = "1.4.1" @@ -5823,9 +6377,9 @@ checksum = "38b58827f4464d87d377d175e90bf58eb00fd8716ff0a62f80356b5e61555d0d" [[package]] name = "skia-bindings" -version = "0.66.3" +version = "0.68.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a42e3db408fbe7beafeadcaf5309c59eb99cc80979cab1b49e2a47539adf8ab" +checksum = "0af1b86d01552a56d70b515e2bc1af9123acffcc679a7410010e2648f59fbec3" dependencies = [ "bindgen", "cc", @@ -5835,17 +6389,17 @@ dependencies = [ "regex", "serde_json", "tar", - "toml 0.7.8", + "toml 0.8.8", "ureq", ] [[package]] name = "skia-safe" -version = "0.66.3" +version = "0.68.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d03680a0ce867756947f2d5fa92078915342f81996c43b61847fed565068f75" +checksum = "ed678303df69daf5b666faf477800ff7fcb7b67316b10a94c31d748d42dd5a83" dependencies = [ - "bitflags 2.4.0", + "bitflags 2.4.1", "lazy_static", "skia-bindings", "winapi", @@ -5863,9 +6417,9 @@ dependencies = [ [[package]] name = "slint" -version = "1.2.2" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9a6f76430dde7dc57d374c37aa3103532813cc275a94b515b5907e91dd19334" +checksum = "3b9d589a30c2812877798eecf2b5cb51e7f2c4531f7c9e8746be6b25a24f37e6" dependencies = [ "const-field-offset", "i-slint-backend-selector", @@ -5880,14 +6434,14 @@ dependencies = [ [[package]] name = "slint-build" -version = "1.2.2" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6edc7309a89f14c685086544ea3dbd7668ccdeb03d774f06879f38237e55815" +checksum = "2edbdfb7bdb1688273656c301ffa221a3939869620e7a12f02d7cae6532098ee" dependencies = [ "i-slint-compiler", "spin_on", "thiserror", - "toml_edit 0.19.15", + "toml_edit 0.20.7", ] [[package]] @@ -5900,9 +6454,9 @@ dependencies = [ [[package]] name = "slint-macros" -version = "1.2.2" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33f96e5ea0574ac69b773b159d43124f7a329107cf60c11516e63d38c2d8c89c" +checksum = "ee1b8b49389eb768793499fce1c60d613ac52d14fe77383a65f233327cd65715" dependencies = [ "i-slint-compiler", "proc-macro2", @@ -5927,9 +6481,9 @@ checksum = "d92359f97e6b417da4328a970cf04a044db104fbd57f7d72cb7ff665bb8806af" [[package]] name = "smallvec" -version = "1.11.1" +version = "1.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "942b4a808e05215192e39f4ab80813e599068285906cc91aa64f923db842bd5a" +checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "smithay-client-toolkit" @@ -5946,8 +6500,33 @@ dependencies = [ "nix 0.24.3", "pkg-config", "wayland-client 0.29.5", - "wayland-cursor", - "wayland-protocols", + "wayland-cursor 0.29.5", + "wayland-protocols 0.29.5", +] + +[[package]] +name = "smithay-client-toolkit" +version = "0.18.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60e3d9941fa3bacf7c2bf4b065304faa14164151254cd16ce1b1bc8fc381600f" +dependencies = [ + "bitflags 2.4.1", + "calloop 0.12.3", + "calloop-wayland-source", + "cursor-icon", + "libc", + "log", + "memmap2 0.9.0", + "rustix 0.38.24", + "thiserror", + "wayland-backend", + "wayland-client 0.31.1", + "wayland-csd-frame", + "wayland-cursor 0.31.0", + "wayland-protocols 0.31.0", + "wayland-protocols-wlr", + "wayland-scanner 0.31.0", + "xkeysym", ] [[package]] @@ -5956,10 +6535,21 @@ version = "0.6.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0a345c870a1fae0b1b779085e81b51e614767c239e93503588e54c5b17f4b0e8" dependencies = [ - "smithay-client-toolkit", + "smithay-client-toolkit 0.16.1", "wayland-client 0.29.5", ] +[[package]] +name = "smithay-clipboard" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0bb62b280ce5a5cba847669933a0948d00904cf83845c944eae96a4738cea1a6" +dependencies = [ + "libc", + "smithay-client-toolkit 0.18.0", + "wayland-backend", +] + [[package]] name = "smol_str" version = "0.2.0" @@ -5971,9 +6561,9 @@ dependencies = [ [[package]] name = "socket2" -version = "0.4.9" +version = "0.4.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64a4a911eed85daf18834cfaa86a79b7d266ff93ff5ba14005426219480ed662" +checksum = "9f7916fc008ca5542385b89a3d3ce689953c143e9304a9bf8beec1de48994c0d" dependencies = [ "libc", "winapi", @@ -5981,9 +6571,9 @@ dependencies = [ [[package]] name = "socket2" -version = "0.5.4" +version = "0.5.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4031e820eb552adee9295814c0ced9e5cf38ddf1e8b7d566d6de8e2538ea989e" +checksum = "7b5fac59a5cb5dd637972e5fca70daf0523c9067fcdc4842f053dae04a18f8e9" dependencies = [ "libc", "windows-sys 0.48.0", @@ -5991,31 +6581,29 @@ dependencies = [ [[package]] name = "softbuffer" -version = "0.3.1" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8bd56fe5e6c6f1881aad2bd37acaef4ac4a3689c970dfcbd87a36a6e60210ec8" +checksum = "826da2ead8e85d1b4ea579fae3d58ec10c81a77d61deab8918c4a4f7514b2948" dependencies = [ "as-raw-xcb-connection", "bytemuck", "cfg_aliases", "cocoa 0.25.0", "core-graphics 0.23.1", - "drm", - "drm-sys", "fastrand 2.0.1", "foreign-types 0.5.0", "js-sys", "log", - "memmap2 0.7.1", - "nix 0.26.4", + "memmap2 0.9.0", "objc", - "raw-window-handle", - "redox_syscall 0.3.5", + "raw-window-handle 0.5.2", + "redox_syscall 0.4.1", + "rustix 0.38.24", "tiny-xlib", "wasm-bindgen", "wayland-backend", - "wayland-client 0.30.2", - "wayland-sys 0.30.1", + "wayland-client 0.31.1", + "wayland-sys 0.31.1", "web-sys", "windows-sys 0.48.0", "x11rb 0.12.0", @@ -6049,12 +6637,6 @@ dependencies = [ "system-deps", ] -[[package]] -name = "spin" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e63cff320ae2c57904679ba7cb63280a3dc4613885beafb148ee7bf9aa9042d" - [[package]] name = "spin" version = "0.9.8" @@ -6161,15 +6743,15 @@ dependencies = [ [[package]] name = "strum_macros" -version = "0.25.2" +version = "0.25.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad8d03b598d3d0fff69bf533ee3ef19b8eeb342729596df84bcc7e1f96ec4059" +checksum = "23dc1fa9ac9c169a78ba62f0b841814b7abae11bdd047b9c58f893439e309ea0" dependencies = [ "heck", "proc-macro2", "quote", "rustversion", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -6194,7 +6776,7 @@ version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1bbdb58577b6301f8d17ae2561f32002a5bae056d444e0f69e611e504a276204" dependencies = [ - "base64 0.21.4", + "base64 0.21.5", "serde", "serde_json", ] @@ -6212,9 +6794,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.37" +version = "2.0.39" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7303ef2c05cd654186cb250d29049a24840ca25d2747c25c0381c8d9e2f582e8" +checksum = "23e78b90f2fcf45d3e842032ce32e3f2d1545ba6636271dcbf24fa306d87be7a" dependencies = [ "proc-macro2", "quote", @@ -6244,14 +6826,14 @@ dependencies = [ [[package]] name = "system-deps" -version = "6.1.2" +version = "6.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94af52f9402f94aac4948a2518b43359be8d9ce6cd9efc1c4de3b2f7b7e897d6" +checksum = "2a2d580ff6a20c55dfb86be5f9c238f67835d0e81cbdea8bf5680e0897320331" dependencies = [ "cfg-expr", "heck", "pkg-config", - "toml 0.8.2", + "toml 0.8.8", "version-compare", ] @@ -6291,7 +6873,7 @@ dependencies = [ "once_cell", "parking_lot", "png", - "raw-window-handle", + "raw-window-handle 0.5.2", "scopeguard", "serde", "tao-macros", @@ -6326,9 +6908,9 @@ dependencies = [ [[package]] name = "target-lexicon" -version = "0.12.11" +version = "0.12.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d0e916b1148c8e263850e1ebcbd046f333e0683c724876bb0da63ea4373dc8a" +checksum = "14c39fd04924ca3a864207c66fc2cd7d22d7c016007f9ce846cbb9326331930a" [[package]] name = "tauri" @@ -6354,7 +6936,7 @@ dependencies = [ "once_cell", "percent-encoding", "rand 0.8.5", - "raw-window-handle", + "raw-window-handle 0.5.2", "reqwest", "semver", "serde", @@ -6403,7 +6985,7 @@ version = "2.0.0-alpha.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5c1f1611ab0896f2693163ba4e8f3e39c02a1b70cdca4314286b5e365a5e08c6" dependencies = [ - "base64 0.21.4", + "base64 0.21.5", "brotli", "ico", "json-patch", @@ -6435,6 +7017,19 @@ dependencies = [ "tauri-utils", ] +[[package]] +name = "tauri-example-with-updater" +version = "0.0.0" +dependencies = [ + "cargo-packager-updater", + "serde", + "serde_json", + "tauri", + "tauri-build", + "tauri-macros", + "tauri-utils", +] + [[package]] name = "tauri-icns" version = "0.1.0" @@ -6470,7 +7065,7 @@ dependencies = [ "http-range", "jni 0.20.0", "rand 0.8.5", - "raw-window-handle", + "raw-window-handle 0.5.2", "serde", "serde_json", "tauri-utils", @@ -6491,7 +7086,7 @@ dependencies = [ "jni 0.20.0", "percent-encoding", "rand 0.8.5", - "raw-window-handle", + "raw-window-handle 0.5.2", "tauri-runtime", "tauri-utils", "uuid", @@ -6542,14 +7137,14 @@ dependencies = [ [[package]] name = "tempfile" -version = "3.8.0" +version = "3.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb94d2f3cc536af71caac6b6fcebf65860b347e7ce0cc9ebe8f70d3e521054ef" +checksum = "7ef1adac450ad7f4b3c28589471ade84f25f731a7a0fe30d71dfa9f60fd808e5" dependencies = [ "cfg-if", "fastrand 2.0.1", - "redox_syscall 0.3.5", - "rustix 0.38.17", + "redox_syscall 0.4.1", + "rustix 0.38.24", "windows-sys 0.48.0", ] @@ -6566,9 +7161,9 @@ dependencies = [ [[package]] name = "termcolor" -version = "1.3.0" +version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6093bad37da69aab9d123a8091e4be0aa4a03e4d601ec641c327398315f62b64" +checksum = "ff1bc3d3f05aff0403e8ac0d92ced918ec05b666a43f83297ccef5bea8a3d449" dependencies = [ "winapi-util", ] @@ -6602,7 +7197,7 @@ checksum = "266b2e40bc00e5a6c09c3584011e08b06f123c00362c92b975ba9843aaaa14b8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -6628,12 +7223,13 @@ dependencies = [ [[package]] name = "time" -version = "0.3.29" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "426f806f4089c493dcac0d24c29c01e2c38baf8e30f1b716ee37e83d200b18fe" +checksum = "c4a34ab300f2dee6e562c10a046fc05e358b29f9bf92277f30c3c8d82275f6f5" dependencies = [ "deranged", "itoa 1.0.9", + "powerfmt", "serde", "time-core", "time-macros", @@ -6683,6 +7279,20 @@ dependencies = [ "tiny-skia-path 0.10.0", ] +[[package]] +name = "tiny-skia" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3b72a92a05db376db09fe6d50b7948d106011761c05a6a45e23e17ee9b556222" +dependencies = [ + "arrayref", + "arrayvec", + "bytemuck", + "cfg-if", + "log", + "tiny-skia-path 0.11.2", +] + [[package]] name = "tiny-skia-path" version = "0.8.4" @@ -6705,6 +7315,17 @@ dependencies = [ "strict-num", ] +[[package]] +name = "tiny-skia-path" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ac3865b9708fc7e1961a65c3a4fa55e984272f33092d3c859929f887fceb647" +dependencies = [ + "arrayref", + "bytemuck", + "strict-num", +] + [[package]] name = "tiny-xlib" version = "0.2.2" @@ -6717,6 +7338,19 @@ dependencies = [ "tracing", ] +[[package]] +name = "tiny_http" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e0d6ef4e10d23c1efb862eecad25c5054429a71958b4eeef85eb5e7170b477ca" +dependencies = [ + "ascii", + "chunked_transfer", + "log", + "time", + "url", +] + [[package]] name = "tinyvec" version = "1.6.0" @@ -6740,9 +7374,9 @@ checksum = "c7c4ceeeca15c8384bbc3e011dbd8fccb7f068a440b752b7d9b32ceb0ca0e2e8" [[package]] name = "tokio" -version = "1.32.0" +version = "1.34.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17ed6077ed6cd6c74735e21f37eb16dc3935f96878b1fe961074089cc80893f9" +checksum = "d0c014766411e834f7af5b8f4cf46257aab4036ca95e9d2c144a10f59ad6f5b9" dependencies = [ "backtrace", "bytes", @@ -6750,27 +7384,47 @@ dependencies = [ "mio", "num_cpus", "pin-project-lite", - "socket2 0.5.4", + "socket2 0.5.5", "tokio-macros", "windows-sys 0.48.0", ] [[package]] name = "tokio-macros" -version = "2.1.0" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e" +checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", +] + +[[package]] +name = "tokio-native-tls" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" +dependencies = [ + "native-tls", + "tokio", +] + +[[package]] +name = "tokio-rustls" +version = "0.24.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c28327cf380ac148141087fbfb9de9d7bd4e84ab5d2c28fbc911d753de8a7081" +dependencies = [ + "rustls", + "tokio", ] [[package]] name = "tokio-util" -version = "0.7.9" +version = "0.7.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d68074620f57a0b21594d9735eb2e98ab38b17f80d3fcb189fca266771ca60d" +checksum = "5419f34732d9eb6ee4c3578b7989078579b7f039cbbb9ca2c4da015749371e15" dependencies = [ "bytes", "futures-core", @@ -6794,21 +7448,21 @@ dependencies = [ [[package]] name = "toml" -version = "0.8.2" +version = "0.8.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "185d8ab0dfbb35cf1399a6344d8484209c088f75f8f68230da55d48d95d43e3d" +checksum = "a1a195ec8c9da26928f773888e0742ca3ca1040c6cd859c919c9f59c1954ab35" dependencies = [ "serde", "serde_spanned", "toml_datetime", - "toml_edit 0.20.2", + "toml_edit 0.21.0", ] [[package]] name = "toml_datetime" -version = "0.6.3" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b" +checksum = "3550f4e9685620ac18a50ed434eb3aec30db8ba93b0287467bca5826ea25baf1" dependencies = [ "serde", ] @@ -6819,7 +7473,7 @@ version = "0.19.15" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" dependencies = [ - "indexmap 2.0.2", + "indexmap 2.1.0", "serde", "serde_spanned", "toml_datetime", @@ -6828,11 +7482,22 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.20.2" +version = "0.20.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70f427fce4d84c72b5b732388bf4a9f4531b53f74e2887e3ecb2481f68f66d81" +dependencies = [ + "indexmap 2.1.0", + "toml_datetime", + "winnow", +] + +[[package]] +name = "toml_edit" +version = "0.21.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "396e4d48bbb2b7554c944bde63101b5ae446cff6ec4a24227428f15eb72ef338" +checksum = "d34d383cd00a163b4a5b85053df514d45bc330f6de7737edfe0a93311d1eaa03" dependencies = [ - "indexmap 2.0.2", + "indexmap 2.1.0", "serde", "serde_spanned", "toml_datetime", @@ -6847,11 +7512,10 @@ checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" [[package]] name = "tracing" -version = "0.1.37" +version = "0.1.40" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ce8c33a8d48bd45d624a6e523445fd21ec13d3653cd51f681abf67418f54eb8" +checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" dependencies = [ - "cfg-if", "pin-project-lite", "tracing-attributes", "tracing-core", @@ -6859,20 +7523,20 @@ dependencies = [ [[package]] name = "tracing-attributes" -version = "0.1.26" +version = "0.1.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f4f31f56159e98206da9efd823404b79b6ef3143b4a7ab76e67b1751b25a4ab" +checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] name = "tracing-core" -version = "0.1.31" +version = "0.1.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0955b8137a1df6f1a2e9a37d8a6656291ff0297c1a97c24e0d8425fe2312f79a" +checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" dependencies = [ "once_cell", "valuable", @@ -6880,20 +7544,20 @@ dependencies = [ [[package]] name = "tracing-log" -version = "0.1.3" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922" +checksum = "ee855f1f400bd0e5c02d150ae5de3840039a3f54b025156404e34c23c03f47c3" dependencies = [ - "lazy_static", "log", + "once_cell", "tracing-core", ] [[package]] name = "tracing-subscriber" -version = "0.3.17" +version = "0.3.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30a651bc37f915e81f087d86e62a18eec5f79550c7faff886f7090b4ea757c77" +checksum = "ad0f048c97dbd9faa9b7df56362b8ebcaa52adb06b498c050d2f4e32f90a7a8b" dependencies = [ "matchers", "nu-ansi-term", @@ -6940,6 +7604,12 @@ version = "0.19.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "49d64318d8311fc2668e48b63969f4343e0a85c4a109aa8460d6672e364b8bd1" +[[package]] +name = "ttf-parser" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "17f77d76d837a7830fe1d4f12b7b4ba4192c1888001c7164257e4bc6d21d96b4" + [[package]] name = "typenum" version = "1.17.0" @@ -7044,9 +7714,9 @@ checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" [[package]] name = "untrusted" -version = "0.7.1" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a156c684c91ea7d62626509bce3cb4e1d9ed5c4d978f7b4352658f96a4c26b4a" +checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" [[package]] name = "ureq" @@ -7054,7 +7724,7 @@ version = "2.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7830e33f6e25723d41a63f77e434159dad02919f18f55a512b5f16f3b1d77138" dependencies = [ - "base64 0.21.4", + "base64 0.21.5", "flate2", "log", "native-tls", @@ -7089,7 +7759,7 @@ version = "0.34.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d2304b933107198a910c1f3219acb65246f2b148f862703cffd51c6e62156abe" dependencies = [ - "base64 0.21.4", + "base64 0.21.5", "log", "pico-args", "usvg-parser", @@ -7158,11 +7828,11 @@ checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" [[package]] name = "uuid" -version = "1.4.1" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79daa5ed5740825c40b389c5e50312b9c86df53fccd33f281df655642b43869d" +checksum = "88ad59a7560b41a70d191093a945f0b87bc1deeda46fb237479708a1d6b6cdfc" dependencies = [ - "getrandom 0.2.10", + "getrandom 0.2.11", "sha1_smol", ] @@ -7236,7 +7906,7 @@ checksum = "6b2b8eecdb8e4284adf5546fc518f048f6dc33e7203dbe36fa93a4add39b31f6" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -7278,9 +7948,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.87" +version = "0.2.88" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7706a72ab36d8cb1f80ffbf0e071533974a60d0a308d01a5d0375bf60499a342" +checksum = "7daec296f25a1bae309c0cd5c29c4b260e510e6d813c286b19eaadf409d40fce" dependencies = [ "cfg-if", "wasm-bindgen-macro", @@ -7288,24 +7958,24 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.87" +version = "0.2.88" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ef2b6d3c510e9625e5fe6f509ab07d66a760f0885d858736483c32ed7809abd" +checksum = "e397f4664c0e4e428e8313a469aaa58310d302159845980fd23b0f22a847f217" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.37" +version = "0.4.38" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c02dbc21516f9f1f04f187958890d7e6026df8d16540b7ad9492bc34a67cea03" +checksum = "9afec9963e3d0994cac82455b2b3502b81a7f40f9a0d32181f7528d9f4b43e02" dependencies = [ "cfg-if", "js-sys", @@ -7315,9 +7985,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.87" +version = "0.2.88" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dee495e55982a3bd48105a7b947fd2a9b4a8ae3010041b9e0faab3f9cd028f1d" +checksum = "5961017b3b08ad5f3fe39f1e79877f8ee7c23c5e5fd5eb80de95abc41f1f16b2" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -7325,22 +7995,22 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.87" +version = "0.2.88" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b" +checksum = "c5353b8dab669f5e10f5bd76df26a9360c748f054f862ff5f3f8aae0c7fb3907" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.87" +version = "0.2.88" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca6ad05a4870b2bf5fe995117d3728437bd27d7cd5f06f13c17443ef369775a1" +checksum = "0d046c5d029ba91a1ed14da14dca44b68bf2f124cfbaf741c54151fdb3e0750b" [[package]] name = "wasm-streams" @@ -7357,17 +8027,16 @@ dependencies = [ [[package]] name = "wayland-backend" -version = "0.1.2" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41b48e27457e8da3b2260ac60d0a94512f5cba36448679f3747c0865b7893ed8" +checksum = "19152ddd73f45f024ed4534d9ca2594e0ef252c1847695255dae47f34df9fbe4" dependencies = [ "cc", "downcast-rs", - "io-lifetimes", "nix 0.26.4", "scoped-tls", "smallvec", - "wayland-sys 0.30.1", + "wayland-sys 0.31.1", ] [[package]] @@ -7388,14 +8057,14 @@ dependencies = [ [[package]] name = "wayland-client" -version = "0.30.2" +version = "0.31.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "489c9654770f674fc7e266b3c579f4053d7551df0ceb392f153adb1f9ed06ac8" +checksum = "1ca7d52347346f5473bf2f56705f360e8440873052e575e55890c4fa57843ed3" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.1", "nix 0.26.4", "wayland-backend", - "wayland-scanner 0.30.1", + "wayland-scanner 0.31.0", ] [[package]] @@ -7410,6 +8079,17 @@ dependencies = [ "wayland-sys 0.29.5", ] +[[package]] +name = "wayland-csd-frame" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "625c5029dbd43d25e6aa9615e88b829a5cad13b2819c4ae129fdbb7c31ab4c7e" +dependencies = [ + "bitflags 2.4.1", + "cursor-icon", + "wayland-backend", +] + [[package]] name = "wayland-cursor" version = "0.29.5" @@ -7421,6 +8101,17 @@ dependencies = [ "xcursor", ] +[[package]] +name = "wayland-cursor" +version = "0.31.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a44aa20ae986659d6c77d64d808a046996a932aa763913864dc40c359ef7ad5b" +dependencies = [ + "nix 0.26.4", + "wayland-client 0.31.1", + "xcursor", +] + [[package]] name = "wayland-protocols" version = "0.29.5" @@ -7433,6 +8124,44 @@ dependencies = [ "wayland-scanner 0.29.5", ] +[[package]] +name = "wayland-protocols" +version = "0.31.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e253d7107ba913923dc253967f35e8561a3c65f914543e46843c88ddd729e21c" +dependencies = [ + "bitflags 2.4.1", + "wayland-backend", + "wayland-client 0.31.1", + "wayland-scanner 0.31.0", +] + +[[package]] +name = "wayland-protocols-plasma" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23803551115ff9ea9bce586860c5c5a971e360825a0309264102a9495a5ff479" +dependencies = [ + "bitflags 2.4.1", + "wayland-backend", + "wayland-client 0.31.1", + "wayland-protocols 0.31.0", + "wayland-scanner 0.31.0", +] + +[[package]] +name = "wayland-protocols-wlr" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ad1f61b76b6c2d8742e10f9ba5c3737f6530b4c243132c2a2ccc8aa96fe25cd6" +dependencies = [ + "bitflags 2.4.1", + "wayland-backend", + "wayland-client 0.31.1", + "wayland-protocols 0.31.0", + "wayland-scanner 0.31.0", +] + [[package]] name = "wayland-scanner" version = "0.29.5" @@ -7446,12 +8175,12 @@ dependencies = [ [[package]] name = "wayland-scanner" -version = "0.30.1" +version = "0.31.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9b873b257fbc32ec909c0eb80dea312076a67014e65e245f5eb69a6b8ab330e" +checksum = "fb8e28403665c9f9513202b7e1ed71ec56fde5c107816843fb14057910b2c09c" dependencies = [ "proc-macro2", - "quick-xml 0.28.2", + "quick-xml 0.30.0", "quote", ] @@ -7478,11 +8207,33 @@ dependencies = [ "pkg-config", ] +[[package]] +name = "wayland-sys" +version = "0.31.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "15a0c8eaff5216d07f226cb7a549159267f3467b289d9a2e52fd3ef5aae2b7af" +dependencies = [ + "dlib", + "log", + "once_cell", + "pkg-config", +] + [[package]] name = "web-sys" -version = "0.3.64" +version = "0.3.65" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5db499c5f66323272151db0e666cd34f78617522fb0c1604d31a27c50c206a85" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "web-time" +version = "0.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b85cbef8c220a6abc02aefd892dfc0fc23afb1c6a426316ec33253a3877249b" +checksum = "57099a701fb3a8043f993e8228dc24229c7b942e2b009a1b962e54489ba1d3bf" dependencies = [ "js-sys", "wasm-bindgen", @@ -7490,9 +8241,9 @@ dependencies = [ [[package]] name = "webbrowser" -version = "0.8.11" +version = "0.8.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2c79b77f525a2d670cb40619d7d9c673d09e0666f72c591ebd7861f84a87e57" +checksum = "82b2391658b02c27719fc5a0a73d6e696285138e8b12fba9d4baa70451023c71" dependencies = [ "core-foundation", "home", @@ -7500,7 +8251,7 @@ dependencies = [ "log", "ndk-context", "objc", - "raw-window-handle", + "raw-window-handle 0.5.2", "url", "web-sys", ] @@ -7608,7 +8359,7 @@ dependencies = [ "either", "home", "once_cell", - "rustix 0.38.17", + "rustix 0.38.24", ] [[package]] @@ -7683,6 +8434,15 @@ dependencies = [ "windows-tokens", ] +[[package]] +name = "windows-core" +version = "0.51.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1f8cf84f35d2db49a46868f947758c7a1138116f7fac3bc844f43ade1292e64" +dependencies = [ + "windows-targets 0.48.5", +] + [[package]] name = "windows-implement" version = "0.44.0" @@ -7943,7 +8703,7 @@ version = "0.28.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9596d90b45384f5281384ab204224876e8e8bf7d58366d9b795ad99aa9894b94" dependencies = [ - "android-activity", + "android-activity 0.4.3", "bitflags 1.3.2", "cfg_aliases", "core-foundation", @@ -7954,29 +8714,78 @@ dependencies = [ "log", "mio", "ndk 0.7.0", - "objc2", + "objc2 0.3.0-beta.3.patch-leaks.3", "once_cell", "orbclient", "percent-encoding", - "raw-window-handle", + "raw-window-handle 0.5.2", "redox_syscall 0.3.5", - "sctk-adwaita", - "smithay-client-toolkit", + "sctk-adwaita 0.5.4", + "smithay-client-toolkit 0.16.1", "wasm-bindgen", "wayland-client 0.29.5", "wayland-commons", - "wayland-protocols", + "wayland-protocols 0.29.5", "wayland-scanner 0.29.5", "web-sys", "windows-sys 0.45.0", "x11-dl", ] +[[package]] +name = "winit" +version = "0.29.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "161598019a9da35ab6c34dc46cd13546cba9dbf9816475d4dd9a639455016563" +dependencies = [ + "ahash", + "android-activity 0.5.0", + "atomic-waker", + "bitflags 2.4.1", + "bytemuck", + "calloop 0.12.3", + "cfg_aliases", + "core-foundation", + "core-graphics 0.23.1", + "cursor-icon", + "icrate", + "js-sys", + "libc", + "log", + "memmap2 0.9.0", + "ndk 0.8.0", + "ndk-sys 0.5.0+25.2.9519653", + "objc2 0.4.1", + "once_cell", + "orbclient", + "percent-encoding", + "raw-window-handle 0.5.2", + "raw-window-handle 0.6.0", + "redox_syscall 0.3.5", + "rustix 0.38.24", + "sctk-adwaita 0.7.0", + "smithay-client-toolkit 0.18.0", + "smol_str", + "unicode-segmentation", + "wasm-bindgen", + "wasm-bindgen-futures", + "wayland-backend", + "wayland-client 0.31.1", + "wayland-protocols 0.31.0", + "wayland-protocols-plasma", + "web-sys", + "web-time", + "windows-sys 0.48.0", + "x11-dl", + "x11rb 0.12.0", + "xkbcommon-dl", +] + [[package]] name = "winnow" -version = "0.5.15" +version = "0.5.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c2e3184b9c4e92ad5167ca73039d0c42476302ab603e2fec4487511f38ccefc" +checksum = "829846f3e3db426d4cee4510841b71a8e58aa2a76b1132579487ae430ccd9c7b" dependencies = [ "memchr", ] @@ -8078,11 +8887,11 @@ dependencies = [ [[package]] name = "x11-clipboard" -version = "0.7.1" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "980b9aa9226c3b7de8e2adb11bf20124327c054e0e5812d2aac0b5b5a87e7464" +checksum = "b41aca1115b1f195f21c541c5efb423470848d48143127d0f07f8b90c27440df" dependencies = [ - "x11rb 0.10.1", + "x11rb 0.12.0", ] [[package]] @@ -8183,6 +8992,19 @@ dependencies = [ "xkeysym", ] +[[package]] +name = "xkbcommon-dl" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6924668544c48c0133152e7eec86d644a056ca3d09275eb8d5cdb9855f9d8699" +dependencies = [ + "bitflags 2.4.1", + "dlib", + "log", + "once_cell", + "xkeysym", +] + [[package]] name = "xkeysym" version = "0.2.0" @@ -8216,8 +9038,8 @@ dependencies = [ "async-broadcast", "async-executor", "async-fs", - "async-io", - "async-lock", + "async-io 1.13.0", + "async-lock 2.8.0", "async-process", "async-recursion", "async-task", @@ -8226,7 +9048,7 @@ dependencies = [ "byteorder", "derivative", "enumflags2", - "event-listener", + "event-listener 2.5.3", "futures-core", "futures-sink", "futures-util", @@ -8254,7 +9076,7 @@ version = "3.14.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "41d1794a946878c0e807f55a397187c11fc7a038ba5d868e7db4f3bd7760bc9d" dependencies = [ - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", "regex", @@ -8275,22 +9097,22 @@ dependencies = [ [[package]] name = "zerocopy" -version = "0.7.25" +version = "0.7.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8cd369a67c0edfef15010f980c3cbe45d7f651deac2cd67ce097cd801de16557" +checksum = "e97e415490559a91254a2979b4829267a57d2fcd741a98eee8b722fb57289aa0" dependencies = [ "zerocopy-derive", ] [[package]] name = "zerocopy-derive" -version = "0.7.25" +version = "0.7.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2f140bda219a26ccc0cdb03dba58af72590c53b22642577d88a927bc5c87d6b" +checksum = "dd7e48ccf166952882ca8bd778a43502c64f33bf94c12ebe2a7f08e5a0f6689f" dependencies = [ "proc-macro2", "quote", - "syn 2.0.37", + "syn 2.0.39", ] [[package]] @@ -8334,7 +9156,7 @@ version = "3.15.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "934d7a7dfc310d6ee06c87ffe88ef4eca7d3e37bb251dece2ef93da8f17d8ecd" dependencies = [ - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", "syn 1.0.109", diff --git a/Cargo.toml b/Cargo.toml index 9fe540fd..8e59fb36 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,5 +1,5 @@ [workspace] -members = ["crates/*", "examples/*", "bindings/*/nodejs"] +members = ["crates/*", "examples/*", "bindings/*/nodejs", "crates/updater/tests/app"] exclude = ["examples/deno", "examples/wails", "examples/electron"] resolver = "2" @@ -20,6 +20,8 @@ dirs = "5.0" semver = "1" base64 = "0.21" tracing = "0.1" +time = "0.3" +tar = "0.4" [profile.release-size-optimized] inherits = "release" diff --git a/crates/packager/Cargo.toml b/crates/packager/Cargo.toml index 25d7ea67..b5a0de31 100644 --- a/crates/packager/Cargo.toml +++ b/crates/packager/Cargo.toml @@ -60,7 +60,7 @@ relative-path = "1.9" walkdir = "2" os_pipe = "1" minisign = "0.7" -tar = "0.4" +tar = { workspace = true } libflate = "2.0" strsim = "0.10" schemars = { workspace = true, optional = true } @@ -87,7 +87,7 @@ ar = "0.9" [target."cfg(target_os = \"macos\")".dependencies] icns = { package = "tauri-icns", version = "0.1" } -time = { version = "0.3", features = [ "formatting" ] } +time = { workspace = true, features = [ "formatting" ] } plist = "1" image = "0.24" tempfile = "3" diff --git a/crates/packager/src/cli/signer/generate.rs b/crates/packager/src/cli/signer/generate.rs index 18a149f0..d816e105 100644 --- a/crates/packager/src/cli/signer/generate.rs +++ b/crates/packager/src/cli/signer/generate.rs @@ -31,7 +31,7 @@ pub fn command(mut options: Options) -> crate::Result<()> { options.password.replace("".into()); } - tracing::info!("Generating a new signgin key."); + tracing::info!("Generating a new signing key."); let keypair = crate::sign::generate_key(options.password)?; match options.path { @@ -45,7 +45,7 @@ pub fn command(mut options: Options) -> crate::Result<()> { } None => { tracing::info!("Finished generating secret key:\n{}", keypair.sk); - tracing::info!("Finished generating publick key:\n{}", keypair.pk); + tracing::info!("Finished generating public key:\n{}", keypair.pk); } } diff --git a/crates/packager/src/lib.rs b/crates/packager/src/lib.rs index 6ed4781a..d80f83af 100644 --- a/crates/packager/src/lib.rs +++ b/crates/packager/src/lib.rs @@ -81,7 +81,7 @@ #![cfg_attr(doc_cfg, feature(doc_cfg))] #![deny(missing_docs)] -use std::path::PathBuf; +use std::{io::Write, path::PathBuf}; mod codesign; mod error; @@ -154,7 +154,10 @@ pub fn sign_outputs( let zip = path.with_extension(extension); let dest_file = util::create_file(&zip)?; let gzip_encoder = libflate::gzip::Encoder::new(dest_file)?; - util::create_tar_from_dir(path, gzip_encoder)?; + let writer = util::create_tar_from_dir(path, gzip_encoder)?; + let mut dest_file = writer.finish().into_result()?; + dest_file.flush()?; + package.paths.push(zip); package.paths.last().unwrap() } else { diff --git a/crates/packager/src/util.rs b/crates/packager/src/util.rs index 8f68bcff..928cb5c7 100644 --- a/crates/packager/src/util.rs +++ b/crates/packager/src/util.rs @@ -225,8 +225,8 @@ pub(crate) enum Bitness { #[cfg(windows)] pub(crate) fn os_bitness() -> crate::Result { use windows_sys::Win32::System::{ - SystemInformation::{PROCESSOR_ARCHITECTURE_AMD64, PROCESSOR_ARCHITECTURE_INTEL}, SystemInformation::{GetNativeSystemInfo, SYSTEM_INFO}, + SystemInformation::{PROCESSOR_ARCHITECTURE_AMD64, PROCESSOR_ARCHITECTURE_INTEL}, }; let mut system_info: SYSTEM_INFO = unsafe { std::mem::zeroed() }; diff --git a/crates/updater/Cargo.toml b/crates/updater/Cargo.toml index 8cfaeee1..8d877bd8 100644 --- a/crates/updater/Cargo.toml +++ b/crates/updater/Cargo.toml @@ -7,4 +7,30 @@ edition.workspace = true license.workspace = true repository.workspace = true +[features] +native-tls = ["reqwest/native-tls"] +native-tls-vendored = ["reqwest/native-tls-vendored"] +rustls-tls = ["reqwest/rustls-tls"] + [dependencies] +reqwest = { version = "0.11", default-features = false, features = [ "json", "stream", "blocking" ] } +thiserror = { workspace = true } +serde = { workspace = true } +serde_json = { workspace = true } +dunce = { workspace = true } +dirs = { workspace = true } +semver = { workspace = true } +base64 = { workspace = true } +time = { workspace = true, features = ["parsing", "formatting"] } +http = "0.2" +url = { version = "2.4", features = ["serde"]} +minisign-verify = "0.2" +ctor = "0.2" +tempfile = "3.8" + +[target."cfg(target_os = \"macos\")".dependencies] +tar = { workspace = true } +flate2 = "1.0.27" + +[dev-dependencies] +tiny_http = "0.11" diff --git a/crates/updater/src/current_exe.rs b/crates/updater/src/current_exe.rs new file mode 100644 index 00000000..7fb9da62 --- /dev/null +++ b/crates/updater/src/current_exe.rs @@ -0,0 +1,154 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// Copyright 2023-2023 CrabNebula Ltd. +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +/// Retrieves the currently running binary's path, taking into account security considerations. +/// +/// The path is cached as soon as possible (before even `main` runs) and that value is returned +/// repeatedly instead of fetching the path every time. It is possible for the path to not be found, +/// or explicitly disabled (see following macOS specific behavior). +/// +/// # Platform-specific behavior +/// +/// On `macOS`, this function will return an error if the original path contained any symlinks +/// due to less protection on macOS regarding symlinks. This behavior can be disabled by setting the +/// `process-relaunch-dangerous-allow-symlink-macos` feature, although it is *highly discouraged*. +/// +/// # Security +/// +/// If the above platform-specific behavior does **not** take place, this function uses the +/// following resolution. +/// +/// We canonicalize the path we received from [`std::env::current_exe`] to resolve any soft links. +/// This avoids the usual issue of needing the file to exist at the passed path because a valid +/// current executable result for our purpose should always exist. Notably, +/// [`std::env::current_exe`] also has a security section that goes over a theoretical attack using +/// hard links. Let's cover some specific topics that relate to different ways an attacker might +/// try to trick this function into returning the wrong binary path. +/// +/// ## Symlinks ("Soft Links") +/// +/// [`std::path::Path::canonicalize`] is used to resolve symbolic links to the original path, +/// including nested symbolic links (`link2 -> link1 -> bin`). On macOS, any results that include +/// a symlink are rejected by default due to lesser symlink protections. This can be disabled, +/// **although discouraged**, with the `process-relaunch-dangerous-allow-symlink-macos` feature. +/// +/// ## Hard Links +/// +/// A [Hard Link] is a named entry that points to a file in the file system. +/// On most systems, this is what you would think of as a "file". The term is +/// used on filesystems that allow multiple entries to point to the same file. +/// The linked [Hard Link] Wikipedia page provides a decent overview. +/// +/// In short, unless the attacker was able to create the link with elevated +/// permissions, it should generally not be possible for them to hard link +/// to a file they do not have permissions to - with exception to possible +/// operating system exploits. +/// +/// There are also some platform-specific information about this below. +/// +/// ### Windows +/// +/// Windows requires a permission to be set for the user to create a symlink +/// or a hard link, regardless of ownership status of the target. Elevated +/// permissions users have the ability to create them. +/// +/// ### macOS +/// +/// macOS allows for the creation of symlinks and hard links to any file. +/// Accessing through those links will fail if the user who owns the links +/// does not have the proper permissions on the original file. +/// +/// ### Linux +/// +/// Linux allows for the creation of symlinks to any file. Accessing the +/// symlink will fail if the user who owns the symlink does not have the +/// proper permissions on the original file. +/// +/// Linux additionally provides a kernel hardening feature since version +/// 3.6 (30 September 2012). Most distributions since then have enabled +/// the protection (setting `fs.protected_hardlinks = 1`) by default, which +/// means that a vast majority of desktop Linux users should have it enabled. +/// **The feature prevents the creation of hardlinks that the user does not own +/// or have read/write access to.** [See the patch that enabled this]. +/// +/// [Hard Link]: https://en.wikipedia.org/wiki/Hard_link +/// [See the patch that enabled this]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=800179c9b8a1e796e441674776d11cd4c05d61d7 +pub fn current_exe() -> std::io::Result { + STARTING_BINARY.cloned() +} + +use ctor::ctor; +use std::{ + io::{Error, ErrorKind, Result}, + path::{Path, PathBuf}, +}; + +/// A cached version of the current binary using [`ctor`] to cache it before even `main` runs. +#[ctor] +#[used] +static STARTING_BINARY: StartingBinary = StartingBinary::new(); + +/// Represents a binary path that was cached when the program was loaded. +struct StartingBinary(std::io::Result); + +impl StartingBinary { + /// Find the starting executable as safely as possible. + fn new() -> Self { + // see notes on current_exe() for security implications + let dangerous_path = match std::env::current_exe() { + Ok(dangerous_path) => dangerous_path, + error @ Err(_) => return Self(error), + }; + + // note: this only checks symlinks on problematic platforms, see implementation below + if let Some(symlink) = Self::has_symlink(&dangerous_path) { + return Self(Err(Error::new( + ErrorKind::InvalidData, + format!("StartingBinary found current_exe() that contains a symlink on a non-allowed platform: {}", symlink.display()), + ))); + } + + // we canonicalize the path to resolve any symlinks to the real exe path + Self(dangerous_path.canonicalize()) + } + + /// A clone of the [`PathBuf`] found to be the starting path. + /// + /// Because [`Error`] is not clone-able, it is recreated instead. + pub(super) fn cloned(&self) -> Result { + self.0 + .as_ref() + .map(Clone::clone) + .map_err(|e| Error::new(e.kind(), e.to_string())) + } + + /// We only care about checking this on macOS currently, as it has the least symlink protections. + #[cfg(any( + not(target_os = "macos"), + feature = "process-relaunch-dangerous-allow-symlink-macos" + ))] + fn has_symlink(_: &Path) -> Option<&Path> { + None + } + + /// We only care about checking this on macOS currently, as it has the least symlink protections. + #[cfg(all( + target_os = "macos", + not(feature = "process-relaunch-dangerous-allow-symlink-macos") + ))] + fn has_symlink(path: &Path) -> Option<&Path> { + path.ancestors().find(|ancestor| { + matches!( + ancestor + .symlink_metadata() + .as_ref() + .map(std::fs::Metadata::file_type) + .as_ref() + .map(std::fs::FileType::is_symlink), + Ok(true) + ) + }) + } +} diff --git a/crates/updater/src/custom_serialization.rs b/crates/updater/src/custom_serialization.rs new file mode 100644 index 00000000..25ad0c1b --- /dev/null +++ b/crates/updater/src/custom_serialization.rs @@ -0,0 +1,97 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// Copyright 2023-2023 CrabNebula Ltd. +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use std::{collections::HashMap, str::FromStr}; + +use semver::Version; +use serde::{de::Error, Deserialize, Deserializer}; +use time::OffsetDateTime; +use url::Url; + +use crate::{ReleaseManifestPlatform, RemoteRelease, RemoteReleaseInner, UpdateFormat}; + +fn parse_version<'de, D>(deserializer: D) -> std::result::Result +where + D: serde::Deserializer<'de>, +{ + let str = String::deserialize(deserializer)?; + Version::from_str(str.trim_start_matches('v')).map_err(Error::custom) +} + +impl<'de> Deserialize<'de> for UpdateFormat { + fn deserialize(deserializer: D) -> std::result::Result + where + D: Deserializer<'de>, + { + let lower = String::deserialize(deserializer)?.to_lowercase(); + let variant = match lower.as_str() { + "nsis" => UpdateFormat::Nsis, + "wix" => UpdateFormat::Wix, + "app" => UpdateFormat::App, + "appimage" => UpdateFormat::AppImage, + _ => { + return Err(serde::de::Error::custom( + "Unkown updater format, expected one of 'nsis', 'wix', 'app' or 'appimage'", + )) + } + }; + + Ok(variant) + } +} + +impl<'de> Deserialize<'de> for RemoteRelease { + fn deserialize(deserializer: D) -> std::result::Result + where + D: Deserializer<'de>, + { + #[derive(Deserialize)] + struct InnerRemoteRelease { + #[serde(alias = "name", deserialize_with = "parse_version")] + version: Version, + notes: Option, + pub_date: Option, + platforms: Option>, + // dynamic platform response + url: Option, + signature: Option, + format: Option, + } + + let release = InnerRemoteRelease::deserialize(deserializer)?; + + let pub_date = if let Some(date) = release.pub_date { + Some( + OffsetDateTime::parse(&date, &time::format_description::well_known::Rfc3339) + .map_err(|e| { + serde::de::Error::custom(format!("invalid value for `pub_date`: {e}")) + })?, + ) + } else { + None + }; + + Ok(RemoteRelease { + version: release.version, + notes: release.notes, + pub_date, + data: if let Some(platforms) = release.platforms { + RemoteReleaseInner::Static { platforms } + } else { + RemoteReleaseInner::Dynamic(ReleaseManifestPlatform { + url: release.url.ok_or_else(|| { + Error::custom("the `url` field was not set on the updater response") + })?, + signature: release.signature.ok_or_else(|| { + Error::custom("the `signature` field was not set on the updater response") + })?, + format: release.format.ok_or_else(|| { + Error::custom("the `format` field was not set on the updater response") + })?, + }) + }, + }) + } +} diff --git a/crates/updater/src/error.rs b/crates/updater/src/error.rs new file mode 100644 index 00000000..e6709272 --- /dev/null +++ b/crates/updater/src/error.rs @@ -0,0 +1,71 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// Copyright 2023-2023 CrabNebula Ltd. +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use thiserror::Error; + +/// All errors that can occur while running the updater. +#[derive(Debug, Error)] +#[non_exhaustive] +pub enum Error { + /// Endpoints are not sent. + #[error("Updater does not have any endpoints set.")] + EmptyEndpoints, + /// IO errors. + #[error(transparent)] + Io(#[from] std::io::Error), + /// Semver errors. + #[error(transparent)] + Semver(#[from] semver::Error), + /// Serialization errors. + #[error(transparent)] + Serialization(#[from] serde_json::Error), + /// Could not fetch a valid response from the server. + #[error("Could not fetch a valid release JSON from the remote")] + ReleaseNotFound, + /// Unsupported app architecture. + #[error("Unsupported application architecture, expected one of `x86`, `x86_64`, `arm` or `aarch64`.")] + UnsupportedArch, + /// Unsupported update fromat. + #[error("Unsupported update format for the current target")] + UnsupportedUpdateFormat, + /// Operating system is not supported. + #[error("Unsupported OS, expected one of `linux`, `macos` or `windows`.")] + UnsupportedOs, + /// Failed to determine updater package extract path + #[error("Failed to determine updater package extract path.")] + FailedToDetermineExtractPath, + /// Url parsing errors. + #[error(transparent)] + UrlParse(#[from] url::ParseError), + /// The platform was not found on the updater JSON response. + #[error("the platform `{0}` was not found on the response `platforms` object")] + TargetNotFound(String), + /// Download failed + #[error("`{0}`")] + Network(String), + /// `minisign_verify` errors. + #[error(transparent)] + Minisign(#[from] minisign_verify::Error), + /// `base64` errors. + #[error(transparent)] + Base64(#[from] base64::DecodeError), + /// UTF8 Errors in signature. + #[error("The signature {0} could not be decoded, please check if it is a valid base64 string. The signature must be the contents of the `.sig` file generated by the Tauri bundler, as a string.")] + SignatureUtf8(String), + /// Temp dir is not on same mount mount. This prevents our updater to rename the AppImage to a temp file. + #[error("temp directory is not on the same mount point as the AppImage")] + TempDirNotOnSameMountPoint, + /// The `reqwest` crate errors. + #[error(transparent)] + Reqwest(#[from] reqwest::Error), + /// The `http` crate errors. + #[error(transparent)] + Http(#[from] http::Error), + /// Error returned when persisting a temporary file fails. + #[error(transparent)] + PersistError(#[from] tempfile::PersistError), +} + +pub type Result = std::result::Result; diff --git a/crates/updater/src/lib.rs b/crates/updater/src/lib.rs index f7c09f9d..2217e146 100644 --- a/crates/updater/src/lib.rs +++ b/crates/updater/src/lib.rs @@ -1,3 +1,880 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // Copyright 2023-2023 CrabNebula Ltd. // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT + +use base64::Engine; +use http::HeaderName; +use minisign_verify::{PublicKey, Signature}; +use reqwest::{ + blocking::Client, + header::{HeaderMap, HeaderValue}, + StatusCode, +}; +use semver::Version; +use serde::{Deserialize, Serialize}; +use std::{ + collections::HashMap, + io::{Cursor, Read}, + path::{Path, PathBuf}, + time::Duration, +}; +use time::OffsetDateTime; +use url::Url; + +use crate::current_exe::current_exe; + +mod current_exe; +mod custom_serialization; +mod error; + +pub use crate::error::*; +pub use http; +pub use reqwest; +pub use semver; +pub use url; + +/// Install modes for the Windows update. +#[derive(Debug, PartialEq, Eq, Clone, Default)] +pub enum WindowsUpdateInstallMode { + /// Specifies there's a basic UI during the installation process, including a final dialog box at the end. + BasicUi, + /// The quiet mode means there's no user interaction required. + /// Requires admin privileges if the installer does. + Quiet, + /// Specifies unattended mode, which means the installation only shows a progress bar. + #[default] + Passive, +} + +impl WindowsUpdateInstallMode { + /// Returns the associated `msiexec.exe` arguments. + pub fn msiexec_args(&self) -> &'static [&'static str] { + match self { + Self::BasicUi => &["/qb+"], + Self::Quiet => &["/quiet"], + Self::Passive => &["/passive"], + } + } + + /// Returns the associated nsis arguments. + pub fn nsis_args(&self) -> &'static [&'static str] { + match self { + Self::Passive => &["/P", "/R"], + Self::Quiet => &["/S", "/R"], + _ => &[], + } + } +} + +/// The updater configuration for Windows. +#[derive(Debug, Default, PartialEq, Eq, Clone)] +pub struct UpdaterWindowsConfig { + /// Additional arguments given to the NSIS or WiX installer. + pub installer_args: Vec, + /// The installation mode for the update on Windows. Defaults to `passive`. + pub install_mode: WindowsUpdateInstallMode, +} + +/// Updater configuration. +#[derive(Debug, Clone, Default)] +pub struct Config { + pub endpoints: Vec, + /// Signature public key. + pub pubkey: String, + /// The Windows configuration for the updater. + pub windows: UpdaterWindowsConfig, +} + +/// Supported update format +#[derive(Debug, Serialize, Copy, Clone)] +pub enum UpdateFormat { + /// The NSIS installer (.exe). + Nsis, + /// The Microsoft Software Installer (.msi) through WiX Toolset. + Wix, + /// The Linux AppImage package (.AppImage). + AppImage, + /// The macOS application bundle (.app). + App, +} + +#[derive(Debug, Deserialize, Serialize, Clone)] +pub struct ReleaseManifestPlatform { + /// Download URL for the platform + pub url: Url, + /// Signature for the platform + pub signature: String, + /// Update format + pub format: UpdateFormat, +} + +#[derive(Debug, Deserialize, Serialize, Clone)] +#[serde(untagged)] +pub enum RemoteReleaseInner { + Dynamic(ReleaseManifestPlatform), + Static { + platforms: HashMap, + }, +} + +/// Information about a release returned by the remote update server. +/// +/// This type can have one of two shapes: Server Format (Dynamic Format) and Static Format. +#[derive(Debug, Clone)] +pub struct RemoteRelease { + /// Version to install. + pub version: Version, + /// Release notes. + pub notes: Option, + /// Release date. + pub pub_date: Option, + /// Release data. + pub data: RemoteReleaseInner, +} + +impl RemoteRelease { + /// The release's download URL for the given target. + pub fn download_url(&self, target: &str) -> Result<&Url> { + match self.data { + RemoteReleaseInner::Dynamic(ref platform) => Ok(&platform.url), + RemoteReleaseInner::Static { ref platforms } => platforms + .get(target) + .map_or(Err(Error::TargetNotFound(target.to_string())), |p| { + Ok(&p.url) + }), + } + } + + /// The release's signature for the given target. + pub fn signature(&self, target: &str) -> Result<&String> { + match self.data { + RemoteReleaseInner::Dynamic(ref platform) => Ok(&platform.signature), + RemoteReleaseInner::Static { ref platforms } => platforms + .get(target) + .map_or(Err(Error::TargetNotFound(target.to_string())), |platform| { + Ok(&platform.signature) + }), + } + } + + /// The release's update format for the given target. + pub fn format(&self, target: &str) -> Result { + match self.data { + RemoteReleaseInner::Dynamic(ref platform) => Ok(platform.format), + RemoteReleaseInner::Static { ref platforms } => platforms + .get(target) + .map_or(Err(Error::TargetNotFound(target.to_string())), |platform| { + Ok(platform.format) + }), + } + } +} + +pub struct UpdaterBuilder { + current_version: Version, + config: Config, + version_comparator: Option bool + Send + Sync>>, + executable_path: Option, + target: Option, + headers: HeaderMap, + timeout: Option, +} + +impl UpdaterBuilder { + pub fn new(current_version: Version, config: crate::Config) -> Self { + Self { + current_version, + config, + version_comparator: None, + executable_path: None, + target: None, + headers: Default::default(), + timeout: None, + } + } + + pub fn version_comparator bool + Send + Sync + 'static>( + mut self, + f: F, + ) -> Self { + self.version_comparator = Some(Box::new(f)); + self + } + + pub fn pub_key(mut self, pub_key: impl Into) -> Self { + self.config.pubkey = pub_key.into(); + self + } + + pub fn target(mut self, target: impl Into) -> Self { + self.target.replace(target.into()); + self + } + + pub fn endpoints(mut self, endpoints: Vec) -> Self { + self.config.endpoints = endpoints; + self + } + + pub fn executable_path>(mut self, p: P) -> Self { + self.executable_path.replace(p.as_ref().into()); + self + } + + pub fn header(mut self, key: K, value: V) -> Result + where + HeaderName: TryFrom, + >::Error: Into, + HeaderValue: TryFrom, + >::Error: Into, + { + let key: std::result::Result = key.try_into().map_err(Into::into); + let value: std::result::Result = + value.try_into().map_err(Into::into); + self.headers.insert(key?, value?); + + Ok(self) + } + + pub fn timeout(mut self, timeout: Duration) -> Self { + self.timeout = Some(timeout); + self + } + + pub fn installer_args(mut self, args: I) -> Self + where + I: IntoIterator, + S: Into, + { + self.config.windows.installer_args = args.into_iter().map(Into::into).collect(); + self + } + + pub fn build(self) -> Result { + if self.config.endpoints.is_empty() { + return Err(Error::EmptyEndpoints); + }; + + let arch = get_updater_arch().ok_or(Error::UnsupportedArch)?; + let (target, json_target) = if let Some(target) = self.target { + (target.clone(), target) + } else { + let target = get_updater_target().ok_or(Error::UnsupportedOs)?; + (target.to_string(), format!("{target}-{arch}")) + }; + + let executable_path = match self.executable_path { + Some(p) => p, + #[cfg(not(any(windows, target_os = "macos")))] + None => { + if let Some(appimage) = std::env::var_os("APPIMAGE").map(PathBuf::from) { + appimage + } else { + current_exe()? + } + } + #[cfg(any(windows, target_os = "macos"))] + _ => current_exe()?, + }; + + // Get the extract_path from the provided executable_path + #[cfg(any(windows, target_os = "macos"))] + let extract_path = extract_path_from_executable(&executable_path)?; + #[cfg(not(any(windows, target_os = "macos")))] + let extract_path = executable_path; + + Ok(Updater { + config: self.config, + current_version: self.current_version, + version_comparator: self.version_comparator, + timeout: self.timeout, + arch, + target, + json_target, + headers: self.headers, + extract_path, + }) + } +} + +pub struct Updater { + config: Config, + current_version: Version, + version_comparator: Option bool + Send + Sync>>, + timeout: Option, + arch: &'static str, + // The `{{target}}` variable we replace in the endpoint + target: String, + // The value we search if the updater server returns a JSON with the `platforms` object + json_target: String, + headers: HeaderMap, + extract_path: PathBuf, +} + +impl Updater { + pub fn check(&self) -> Result> { + // we want JSON only + let mut headers = self.headers.clone(); + headers.insert("Accept", HeaderValue::from_str("application/json").unwrap()); + + // Set SSL certs for linux if they aren't available. + #[cfg(target_os = "linux")] + { + if std::env::var_os("SSL_CERT_FILE").is_none() { + std::env::set_var("SSL_CERT_FILE", "/etc/ssl/certs/ca-certificates.crt"); + } + if std::env::var_os("SSL_CERT_DIR").is_none() { + std::env::set_var("SSL_CERT_DIR", "/etc/ssl/certs"); + } + } + + let mut remote_release: Option = None; + let mut last_error: Option = None; + for url in &self.config.endpoints { + // replace {{current_version}}, {{target}} and {{arch}} in the provided URL + // this is useful if we need to query example + // https://releases.myapp.com/update/{{target}}/{{arch}}/{{current_version}} + // will be translated into -> + // https://releases.myapp.com/update/macos/aarch64/1.0.0 + // The main objective is if the update URL is defined via the Cargo.toml + // the URL will be generated dynamically + let url: Url = url + .to_string() + // url::Url automatically url-encodes the string + .replace( + "%7B%7Bcurrent_version%7D%7D", + &self.current_version.to_string(), + ) + .replace("%7B%7Btarget%7D%7D", &self.target) + .replace("%7B%7Barch%7D%7D", self.arch) + .parse()?; + + let mut request = Client::new().get(url).headers(headers.clone()); + if let Some(timeout) = self.timeout { + request = request.timeout(timeout); + } + let response = request.send(); + + if let Ok(res) = response { + if res.status().is_success() { + // no updates found! + if StatusCode::NO_CONTENT == res.status() { + return Ok(None); + }; + + match serde_json::from_value::(res.json()?).map_err(Into::into) { + Ok(release) => { + last_error = None; + remote_release = Some(release); + // we found a relase, break the loop + break; + } + Err(err) => last_error = Some(err), + } + } + } + } + + // Last error is cleaned on success. + // Shouldn't be triggered if we had a successfull call + if let Some(error) = last_error { + return Err(error); + } + + // Extracted remote metadata + let release = remote_release.ok_or(Error::ReleaseNotFound)?; + + let should_update = match self.version_comparator.as_ref() { + Some(comparator) => comparator(self.current_version.clone(), release.clone()), + None => release.version > self.current_version, + }; + + let update = if should_update { + Some(Update { + current_version: self.current_version.to_string(), + config: self.config.clone(), + target: self.target.clone(), + extract_path: self.extract_path.clone(), + version: release.version.to_string(), + date: release.pub_date, + download_url: release.download_url(&self.json_target)?.to_owned(), + body: release.notes.clone(), + signature: release.signature(&self.json_target)?.to_owned(), + timeout: self.timeout, + headers: self.headers.clone(), + format: release.format(&self.json_target)?, + }) + } else { + None + }; + + Ok(update) + } +} + +#[derive(Debug, Clone)] +pub struct Update { + config: Config, + /// Update description + pub body: Option, + /// Version used to check for update + pub current_version: String, + /// Version announced + pub version: String, + /// Update publish date + pub date: Option, + /// Target + pub target: String, + /// Extract path + #[allow(unused)] + extract_path: PathBuf, + /// Download URL announced + pub download_url: Url, + /// Signature announced + pub signature: String, + /// Request timeout + pub timeout: Option, + /// Request headers + pub headers: HeaderMap, + /// Update format + pub format: UpdateFormat, +} + +impl Update { + /// Downloads the updater package, verifies it then return it as bytes. + /// + /// Use [`Update::install`] to install it + pub fn download), D: FnOnce()>( + &self, + on_chunk: C, + on_download_finish: D, + ) -> Result> { + // set our headers + let mut headers = self.headers.clone(); + headers.insert( + "Accept", + HeaderValue::from_str("application/octet-stream").unwrap(), + ); + headers.insert( + "User-Agent", + HeaderValue::from_str("cargo-packager-updater").unwrap(), + ); + + let mut request = Client::new() + .get(self.download_url.clone()) + .headers(headers); + if let Some(timeout) = self.timeout { + request = request.timeout(timeout); + } + + struct DownloadProgress)> { + content_length: Option, + inner: R, + on_chunk: C, + } + + impl)> Read for DownloadProgress { + fn read(&mut self, buf: &mut [u8]) -> std::io::Result { + self.inner.read(buf).map(|n| { + (self.on_chunk)(n, self.content_length); + n + }) + } + } + + let response = request.send()?; + + if !response.status().is_success() { + return Err(Error::Network(format!( + "Download request failed with status: {}", + response.status() + ))); + } + + let mut source = DownloadProgress { + content_length: response + .headers() + .get("Content-Length") + .and_then(|value| value.to_str().ok()) + .and_then(|value| value.parse().ok()), + inner: response, + on_chunk, + }; + + let mut buffer = Vec::new(); + + let _ = std::io::copy(&mut source, &mut buffer)?; + on_download_finish(); + + let mut update_buffer = Cursor::new(&buffer); + + verify_signature(&mut update_buffer, &self.signature, &self.config.pubkey)?; + + Ok(buffer) + } + + /// Installs the updater package downloaded by [`Update::download`] + pub fn install(&self, bytes: Vec) -> Result<()> { + self.install_inner(bytes) + } + + /// Downloads and installs the updater package + pub fn download_and_install), D: FnOnce()>( + &self, + on_chunk: C, + on_download_finish: D, + ) -> Result<()> { + let bytes = self.download(on_chunk, on_download_finish)?; + self.install(bytes) + } + + // Windows + // + // ### Expected installers: + // │── [AppName]_[version]_x64.msi # Application MSI + // │── [AppName]_[version]_x64-setup.exe # NSIS installer + // └── ... + #[cfg(windows)] + fn install_inner(&self, bytes: Vec) -> Result<()> { + use std::{io::Write, process::Command}; + + let extension = match self.format { + UpdateFormat::Nsis => ".exe", + UpdateFormat::Wix => ".msi", + _ => return Err(crate::Error::UnsupportedUpdateFormat), + }; + + let mut temp_file = tempfile::Builder::new().suffix(extension).tempfile()?; + temp_file.write_all(&bytes)?; + let (f, path) = temp_file.keep()?; + drop(f); + + let system_root = std::env::var("SYSTEMROOT"); + let powershell_path = system_root.as_ref().map_or_else( + |_| "powershell.exe".to_string(), + |p| format!("{p}\\System32\\WindowsPowerShell\\v1.0\\powershell.exe"), + ); + + // we support 2 type of files exe & msi for now + // If it's an `exe` we expect an installer not a runtime. + match self.format { + UpdateFormat::Nsis => { + // we need to wrap the installer path in quotes for Start-Process + let mut installer_arg = std::ffi::OsString::new(); + installer_arg.push("\""); + installer_arg.push(&path); + installer_arg.push("\""); + + // Run the installer + Command::new(powershell_path) + .args(["-NoProfile", "-WindowStyle", "Hidden"]) + .args(["Start-Process"]) + .arg(installer_arg) + .arg("-ArgumentList") + .arg( + [ + self.config.windows.install_mode.nsis_args(), + self.config + .windows + .installer_args + .iter() + .map(AsRef::as_ref) + .collect::>() + .as_slice(), + ] + .concat() + .join(", "), + ) + .spawn() + .expect("installer failed to start"); + + std::process::exit(0); + } + UpdateFormat::Wix => { + { + // we need to wrap the current exe path in quotes for Start-Process + let mut current_exe_arg = std::ffi::OsString::new(); + current_exe_arg.push("\""); + current_exe_arg.push(current_exe()?); + current_exe_arg.push("\""); + + let mut msi_path_arg = std::ffi::OsString::new(); + msi_path_arg.push("\"\"\""); + msi_path_arg.push(&path); + msi_path_arg.push("\"\"\""); + + let msiexec_args = self + .config + .windows + .install_mode + .msiexec_args() + .iter() + .map(|p| p.to_string()) + .collect::>(); + + // run the installer and relaunch the application + let powershell_install_res = Command::new(powershell_path) + .args(["-NoProfile", "-WindowStyle", "Hidden"]) + .args([ + "Start-Process", + "-Wait", + "-FilePath", + "$env:SYSTEMROOT\\System32\\msiexec.exe", + "-ArgumentList", + ]) + .arg("/i,") + .arg(&msi_path_arg) + .arg(format!(", {}, /promptrestart;", msiexec_args.join(", "))) + .arg("Start-Process") + .arg(current_exe_arg) + .spawn(); + if powershell_install_res.is_err() { + // fallback to running msiexec directly - relaunch won't be available + // we use this here in case powershell fails in an older machine somehow + let msiexec_path = system_root.as_ref().map_or_else( + |_| "msiexec.exe".to_string(), + |p| format!("{p}\\System32\\msiexec.exe"), + ); + let _ = Command::new(msiexec_path) + .arg("/i") + .arg(msi_path_arg) + .args(msiexec_args) + .arg("/promptrestart") + .spawn(); + } + + std::process::exit(0); + } + } + _ => unreachable!(), + } + } + + // Linux (AppImage) + // + // ### Expected structure: + // ├── [AppName]_[version]_amd64.AppImage.tar.gz # GZ generated by cargo-packager + // │ └──[AppName]_[version]_amd64.AppImage # Application AppImage + // └── ... + // + // We should have an AppImage already installed to be able to copy and install + // the extract_path is the current AppImage path + // tmp_dir is where our new AppImage is found + #[cfg(any( + target_os = "linux", + target_os = "dragonfly", + target_os = "freebsd", + target_os = "netbsd", + target_os = "openbsd" + ))] + fn install_inner(&self, bytes: Vec) -> Result<()> { + match self.format { + UpdateFormat::AppImage => {} + _ => return Err(crate::Error::UnsupportedUpdateFormat), + }; + + let extract_path_metadata = self.extract_path.metadata()?; + let tmp_dir_locations = vec![ + Box::new(|| Some(std::env::temp_dir())) as Box Option>, + Box::new(dirs::cache_dir), + Box::new(|| Some(self.extract_path.parent().unwrap().to_path_buf())), + ]; + + for tmp_dir_location in tmp_dir_locations { + if let Some(tmp_dir_root) = tmp_dir_location() { + use std::os::unix::fs::{MetadataExt, PermissionsExt}; + + let tmp_dir = tempfile::Builder::new() + .prefix("current_app") + .tempdir_in(tmp_dir_root)?; + let tmp_dir_metadata = tmp_dir.path().metadata()?; + + if extract_path_metadata.dev() == tmp_dir_metadata.dev() { + let mut perms = tmp_dir_metadata.permissions(); + perms.set_mode(0o700); + std::fs::set_permissions(&tmp_dir, perms)?; + + let tmp_app_image = tmp_dir.path().join("current_app.AppImage"); + + // get metadata to restore later + let metadata = self.extract_path.metadata()?; + + // create a backup of our current app image + std::fs::rename(&self.extract_path, &tmp_app_image)?; + + // if something went wrong during the extraction, we should restore previous app + if let Err(err) = std::fs::write(&self.extract_path, bytes).and_then(|_| { + std::fs::set_permissions(&self.extract_path, metadata.permissions()) + }) { + std::fs::rename(tmp_app_image, &self.extract_path)?; + return Err(err.into()); + } + + // early finish we have everything we need here + return Ok(()); + } + } + } + + Err(Error::TempDirNotOnSameMountPoint) + } + + // MacOS + // + // ### Expected structure: + // ├── [AppName]_[version]_x64.app.tar.gz # GZ generated by cargo-packager + // │ └──[AppName].app # Main application + // │ └── Contents # Application contents... + // │ └── ... + // └── ... + #[cfg(target_os = "macos")] + fn install_inner(&self, bytes: Vec) -> Result<()> { + use flate2::read::GzDecoder; + + let cursor = Cursor::new(bytes); + let mut extracted_files: Vec = Vec::new(); + + // the first file in the tar.gz will always be + // /Contents + let tmp_dir = tempfile::Builder::new().prefix("current_app").tempdir()?; + + // create backup of our current app + std::fs::rename(&self.extract_path, tmp_dir.path())?; + + let decoder = GzDecoder::new(cursor); + let mut archive = tar::Archive::new(decoder); + + std::fs::create_dir(&self.extract_path)?; + + for entry in archive.entries()? { + let mut entry = entry?; + + let extraction_path = &self.extract_path.join(entry.path()?); + + // if something went wrong during the extraction, we should restore previous app + if let Err(err) = entry.unpack(extraction_path) { + for file in extracted_files.iter().rev() { + // delete all the files we extracted + if file.is_dir() { + std::fs::remove_dir(file)?; + } else { + std::fs::remove_file(file)?; + } + } + std::fs::rename(tmp_dir.path(), &self.extract_path)?; + return Err(err.into()); + } + + extracted_files.push(extraction_path.to_path_buf()); + } + + let _ = std::process::Command::new("touch") + .arg(&self.extract_path) + .status(); + + Ok(()) + } +} + +/// Gets the target string used on the updater. +pub fn target() -> Option { + if let (Some(target), Some(arch)) = (get_updater_target(), get_updater_arch()) { + Some(format!("{target}-{arch}")) + } else { + None + } +} + +pub(crate) fn get_updater_target() -> Option<&'static str> { + if cfg!(target_os = "linux") { + Some("linux") + } else if cfg!(target_os = "macos") { + Some("macos") + } else if cfg!(target_os = "windows") { + Some("windows") + } else { + None + } +} + +pub(crate) fn get_updater_arch() -> Option<&'static str> { + if cfg!(target_arch = "x86") { + Some("i686") + } else if cfg!(target_arch = "x86_64") { + Some("x86_64") + } else if cfg!(target_arch = "arm") { + Some("armv7") + } else if cfg!(target_arch = "aarch64") { + Some("aarch64") + } else { + None + } +} + +#[cfg(any(windows, target_os = "macos"))] +pub fn extract_path_from_executable(executable_path: &Path) -> Result { + // Return the path of the current executable by default + // Example C:\Program Files\My App\ + let extract_path = executable_path + .parent() + .map(PathBuf::from) + .ok_or(Error::FailedToDetermineExtractPath)?; + + // MacOS example binary is in /Applications/TestApp.app/Contents/MacOS/myApp + // We need to get /Applications/.app + // TODO(lemarier): Need a better way here + // Maybe we could search for <*.app> to get the right path + #[cfg(target_os = "macos")] + if extract_path + .display() + .to_string() + .contains("Contents/MacOS") + { + return extract_path + .parent() + .map(PathBuf::from) + .ok_or(Error::FailedToDetermineExtractPath)? + .parent() + .map(PathBuf::from) + .ok_or(Error::FailedToDetermineExtractPath); + } + + Ok(extract_path) +} + +// Validate signature +// need to be public because its been used +// by our tests in the bundler +// +// NOTE: The buffer position is not reset. +pub fn verify_signature( + archive_reader: &mut R, + release_signature: &str, + pub_key: &str, +) -> Result +where + R: Read, +{ + // we need to convert the pub key + let pub_key_decoded = base64_to_string(pub_key)?; + let public_key = PublicKey::decode(&pub_key_decoded)?; + let signature_base64_decoded = base64_to_string(release_signature)?; + let signature = Signature::decode(&signature_base64_decoded)?; + + // read all bytes until EOF in the buffer + let mut data = Vec::new(); + archive_reader.read_to_end(&mut data)?; + + // Validate signature or bail out + public_key.verify(&data, &signature, true)?; + Ok(true) +} + +fn base64_to_string(base64_string: &str) -> Result { + let decoded_string = &base64::engine::general_purpose::STANDARD.decode(base64_string)?; + let result = std::str::from_utf8(decoded_string) + .map_err(|_| Error::SignatureUtf8(base64_string.into()))? + .to_string(); + Ok(result) +} diff --git a/crates/updater/tests/app/32x32.png b/crates/updater/tests/app/32x32.png new file mode 100644 index 00000000..d572cbf0 Binary files /dev/null and b/crates/updater/tests/app/32x32.png differ diff --git a/crates/updater/tests/app/Cargo.toml b/crates/updater/tests/app/Cargo.toml new file mode 100644 index 00000000..3e23c312 --- /dev/null +++ b/crates/updater/tests/app/Cargo.toml @@ -0,0 +1,6 @@ +[package] +name = "cargo-packager-updater-app-test" +version = "0.1.0" + +[dependencies] +cargo-packager-updater = { path = "../.." } diff --git a/crates/updater/tests/app/src/main.rs b/crates/updater/tests/app/src/main.rs new file mode 100644 index 00000000..290c0dbf --- /dev/null +++ b/crates/updater/tests/app/src/main.rs @@ -0,0 +1,67 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// Copyright 2023-2023 CrabNebula Ltd. +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +fn main() { + #[allow(clippy::option_env_unwrap)] + let version = option_env!("APP_VERSION").unwrap(); + let mut builder = cargo_packager_updater::UpdaterBuilder::new( + version.parse().unwrap(), + cargo_packager_updater::Config { + pubkey: "dW50cnVzdGVkIGNvbW1lbnQ6IG1pbmlzaWduIHB1YmxpYyBrZXk6IDQ2Njc0OTE5Mzk2Q0ExODkKUldTSm9XdzVHVWxuUmtJdjB4RnRXZGVqR3NQaU5SVitoTk1qNFFWQ3pjL2hZWFVDOFNrcEVvVlcK".into(), + endpoints: vec!["http://localhost:3007".parse().unwrap()], + ..Default::default() + }, + ); + let format = std::env::var("UPDATER_FORMAT").unwrap_or_default(); + + match format.as_str() { + "nsis" => { + // /D sets the default installation directory ($INSTDIR), + // overriding InstallDir and InstallDirRegKey. + // It must be the last parameter used in the command line and must not contain any quotes, even if the path contains spaces. + // Only absolute paths are supported. + // NOTE: we only need this because this is an integration test and we don't want to install the app in the programs folder + builder = builder.installer_args(vec![format!( + "/D={}", + std::env::current_exe().unwrap().parent().unwrap().display() + )]); + } + #[cfg(any( + target_os = "linux", + target_os = "dragonfly", + target_os = "freebsd", + target_os = "netbsd", + target_os = "openbsd" + ))] + "appimage" => { + if let Some(p) = std::env::var_os("APPIMAGE") { + builder = builder.executable_path(p); + } + } + _ => {} + } + + let updater = builder.build().unwrap(); + + println!("{version}"); + + match updater.check() { + Ok(Some(update)) => { + if let Err(e) = update.download_and_install(|_, _| {}, || {}) { + println!("{e}"); + std::process::exit(1); + } + + std::process::exit(0); + } + Ok(None) => { + std::process::exit(0); + } + Err(e) => { + println!("{e}"); + std::process::exit(1); + } + } +} diff --git a/crates/updater/tests/update.rs b/crates/updater/tests/update.rs new file mode 100644 index 00000000..cd3b0a5b --- /dev/null +++ b/crates/updater/tests/update.rs @@ -0,0 +1,275 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// Copyright 2023-2023 CrabNebula Ltd. +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +#![allow(dead_code, unused_imports)] + +use std::{ + collections::HashMap, + fs::File, + path::{Path, PathBuf}, + process::Command, +}; + +use serde::Serialize; + +const UPDATER_PRIVATE_KEY: &str = "dW50cnVzdGVkIGNvbW1lbnQ6IHJzaWduIGVuY3J5cHRlZCBzZWNyZXQga2V5ClJXUlRZMEl5VU1qSHBMT0E4R0JCVGZzbUMzb3ZXeGpGY1NSdm9OaUxaVTFuajd0T2ZKZ0FBQkFBQUFBQUFBQUFBQUlBQUFBQWlhRnNPUmxKWjBiWnJ6M29Cd0RwOUpqTW1yOFFQK3JTOGdKSi9CajlHZktHajI2ZnprbEM0VUl2MHhGdFdkZWpHc1BpTlJWK2hOTWo0UVZDemMvaFlYVUM4U2twRW9WV1JHenNzUkRKT2RXQ1FCeXlkYUwxelhacmtxOGZJOG1Nb1R6b0VEcWFLVUk9Cg=="; + +#[derive(Serialize)] +struct PlatformUpdate { + signature: String, + url: &'static str, + format: &'static str, +} + +#[derive(Serialize)] +struct Update { + version: &'static str, + date: String, + platforms: HashMap, +} + +fn build_app(cwd: &Path, root_dir: &Path, version: &str, target: &[UpdaterFormat]) { + let mut command = Command::new("cargo"); + command + .args([ + "run", + "--package", + "cargo-packager", + "--", + "--verbose", + "-f", + &target.iter().map(|t|t.name()).collect::>().join(","), + "-c", + ]) + .arg(format!(r#"{{"outDir":"{}","beforePackagingCommand": "cargo build", "identifier": "com.updater-app.test", "productName": "CargoPackagerAppUpdaterTest", "version": "{version}", "icons": ["32x32.png"], "binaries": [{{"path": "cargo-packager-updater-app-test", "main": true}}]}}"#, root_dir.join("target/debug").to_string_lossy().replace("\\\\?\\", "").replace('\\', "\\\\"))) + .env("CARGO_PACKAGER_SIGN_PRIVATE_KEY", UPDATER_PRIVATE_KEY) + .env("CARGO_PACKAGER_SIGN_PRIVATE_KEY_PASSWORD", "") + // This is read by the updater app test + .env("APP_VERSION", version) + .current_dir(cwd.join("tests/app")); + + let status = command + .status() + .expect("failed to run cargo-packager to package app"); + + if !status.code().map(|c| c == 0).unwrap_or(true) { + panic!("failed to package app with exit code: {:?}", status.code()); + } +} + +#[derive(Copy, Clone)] +enum UpdaterFormat { + AppImage, + + App, + + Wix, + Nsis, +} + +impl UpdaterFormat { + fn name(self) -> &'static str { + match self { + Self::AppImage => "appimage", + Self::App => "app", + Self::Wix => "wix", + Self::Nsis => "nsis", + } + } + + fn default() -> &'static [Self] { + #[cfg(any(target_os = "macos", target_os = "ios"))] + return &[Self::App]; + #[cfg(target_os = "linux")] + return &[Self::AppImage]; + #[cfg(windows)] + return &[Self::Nsis, Self::Wix]; + } +} + +#[cfg(target_os = "linux")] +fn package_paths(root_dir: &Path, version: &str) -> Vec<(UpdaterFormat, PathBuf)> { + vec![( + UpdaterFormat::AppImage, + root_dir.join(format!( + "target/debug/cargo-packager-updater-app-test_{version}_x86_64.AppImage" + )), + )] +} + +#[cfg(target_os = "macos")] +fn package_paths(root_dir: &Path, _version: &str) -> Vec<(UpdaterFormat, PathBuf)> { + vec![( + UpdaterFormat::App, + root_dir.join("target/debug/CargoPackagerAppUpdaterTest.app"), + )] +} + +#[cfg(windows)] +fn package_paths(root_dir: &Path, version: &str) -> Vec<(UpdaterFormat, PathBuf)> { + vec![ + ( + UpdaterFormat::Nsis, + root_dir.join(format!( + "target/debug/cargo-packager-updater-app-test_{version}_x64-setup.exe" + )), + ), + ( + UpdaterFormat::Wix, + root_dir.join(format!( + "target/debug/cargo-packager-updater-app-test_{version}_x64_en-US.msi" + )), + ), + ] +} + +#[test] +#[ignore] +fn update_app() { + let target = + cargo_packager_updater::target().expect("running updater test in an unsupported platform"); + let manifest_dir = PathBuf::from(env!("CARGO_MANIFEST_DIR")); + let root_dir = manifest_dir.join("../..").canonicalize().unwrap(); + + // bundle app update + build_app(&manifest_dir, &root_dir, "1.0.0", UpdaterFormat::default()); + + for (updater_format, out_package_path) in package_paths(&root_dir, "1.0.0") { + let out_package_ext = out_package_path.extension().unwrap().to_str().unwrap(); + + let out_updater_path = if out_package_path.is_dir() { + out_package_path.with_extension(format!("{}.{}", out_package_ext, "tar.gz")) + } else { + out_package_path + }; + + let signature_path = out_updater_path.with_extension(format!( + "{}.sig", + out_updater_path.extension().unwrap().to_str().unwrap() + )); + let signature = std::fs::read_to_string(&signature_path).unwrap_or_else(|_| { + panic!("failed to read signature file {}", signature_path.display()) + }); + + #[cfg(target_os = "macos")] + let updater_path = { + // we need to move it otherwise it'll be overwritten when we build the next app + let updater_path = out_updater_path.with_file_name(format!( + "update-{}", + out_updater_path.file_name().unwrap().to_str().unwrap() + )); + std::fs::rename(&out_updater_path, &updater_path).expect("failed to rename bundle"); + updater_path + }; + #[cfg(not(target_os = "macos"))] + let updater_path = out_updater_path; + + let target = target.clone(); + std::thread::spawn(move || { + // start the updater server + let server = + tiny_http::Server::http("localhost:3007").expect("failed to start updater server"); + + loop { + if let Ok(request) = server.recv() { + match request.url() { + "/" => { + let mut platforms = HashMap::new(); + + platforms.insert( + target.clone(), + PlatformUpdate { + signature: signature.clone(), + url: "http://localhost:3007/download", + format: updater_format.name(), + }, + ); + let body = serde_json::to_vec(&Update { + version: "1.0.0", + date: time::OffsetDateTime::now_utc() + .format(&time::format_description::well_known::Rfc3339) + .unwrap(), + platforms, + }) + .unwrap(); + let len = body.len(); + let response = tiny_http::Response::new( + tiny_http::StatusCode(200), + Vec::new(), + std::io::Cursor::new(body), + Some(len), + None, + ); + let _ = request.respond(response); + } + "/download" => { + let _ = request.respond(tiny_http::Response::from_file( + File::open(&updater_path).unwrap_or_else(|_| { + panic!("failed to open package {}", updater_path.display()) + }), + )); + // close server + return; + } + _ => (), + } + } + } + }); + + // bundle initial app version + build_app(&manifest_dir, &root_dir, "0.1.0", &[updater_format]); + + let mut binary_cmd = if cfg!(windows) { + Command::new(root_dir.join("target/debug/cargo-packager-updater-app-test.exe")) + } else if cfg!(target_os = "macos") { + Command::new( + package_paths(&root_dir, "0.1.0") + .first() + .unwrap() + .1 + .join("Contents/MacOS/cargo-packager-updater-app-test"), + ) + } else { + Command::new(&package_paths(&root_dir, "0.1.0").first().unwrap().1) + }; + + // This is read by the updater app test + binary_cmd.env("UPDATER_FORMAT", updater_format.name()); + + let status = binary_cmd.status().expect("failed to run app"); + + if !status.success() { + panic!("failed to run app"); + } + + // wait until the update is finished and the new version has been installed + // before starting another updater test, this is because we use the same starting binary + // and we can't use it while the updater is installing it + let mut counter = 0; + loop { + std::thread::sleep(std::time::Duration::from_secs(2)); + match binary_cmd.output() { + Ok(o) => { + let output = String::from_utf8_lossy(&o.stdout).to_string(); + let version = output.split_once('\n').unwrap().0; + if version == "1.0.0" { + break; + } + println!("unexpected output {output}"); + eprintln!("stderr: {}", String::from_utf8_lossy(&o.stderr)); + } + Err(e) => { + eprintln!("failed to check if app was updated: {e}"); + } + } + + counter += 1; + if counter == 10 { + panic!("updater test timedout and couldn't verify the update has happened") + } + } + } +} diff --git a/deny.toml b/deny.toml index d290277d..a85c8ba1 100644 --- a/deny.toml +++ b/deny.toml @@ -3,12 +3,21 @@ targets = [ { triple = "x86_64-unknown-linux-gnu" }, { triple = "aarch64-unknown-linux-gnu" }, { triple = "x86_64-pc-windows-msvc" }, + { triple = "i686-pc-windows-msvc" }, { triple = "x86_64-apple-darwin" }, { triple = "aarch64-apple-darwin" }, ] # exclude examples and their dependecies -exclude = ["dioxus-example", "egui-example", "slint-example", "tauri-example", "wry-example"] +exclude = [ + "dioxus-example", + "egui-example", + "slint-example", + "tauri-example", + "tauri-example-with-updater", + "wry-example", + "cargo-packager-updater-app-test", +] [licenses] # List of explicitly allowed licenses @@ -24,7 +33,7 @@ allow = [ "MPL-2.0", "BSD-3-Clause", "OpenSSL", - "Zlib" + "Zlib", ] # Sigh @@ -45,4 +54,4 @@ license-files = [{ path = "LICENSE", hash = 0xbd0eed23 }] # published to private registries. # To see how to mark a crate as unpublished (to the official registry), # visit https://doc.rust-lang.org/cargo/reference/manifest.html#the-publish-field. -ignore = true \ No newline at end of file +ignore = true diff --git a/examples/tauri-with-updater/.gitignore b/examples/tauri-with-updater/.gitignore new file mode 100644 index 00000000..54466f5b --- /dev/null +++ b/examples/tauri-with-updater/.gitignore @@ -0,0 +1,2 @@ +/target + diff --git a/examples/tauri-with-updater/Cargo.toml b/examples/tauri-with-updater/Cargo.toml new file mode 100644 index 00000000..ac86c5de --- /dev/null +++ b/examples/tauri-with-updater/Cargo.toml @@ -0,0 +1,106 @@ +[package] +name = "tauri-example-with-updater" +version = "0.0.0" +edition = "2021" +publish = false + +[build-dependencies] +tauri-build = { version = "=2.0.0-alpha.6", features = [] } + +[dependencies] +tauri = { version = "=2.0.0-alpha.10", features = ["devtools"] } +tauri-utils = { version = "=2.0.0-alpha.6", features = [] } +tauri-macros = "=2.0.0-alpha.6" +serde.workspace = true +serde_json.workspace = true +cargo-packager-updater = { path = "../../crates/updater" } + +[features] +# this feature is used for production builds or when `devPath` points to the filesystem +# DO NOT REMOVE!! +custom-protocol = ["tauri/custom-protocol"] + +[package.metadata.packager] +before-packaging-command = "cargo tauri build" +product-name = "Tauri example (with updater)" +identifier = "com.tauri-with-updater.example" +resources = [ + "Cargo.toml", + "../../README.md", + "icons/*", + "src", + { src = "src-ui/assets/tauri.svg", target = "path/to/tauri.svg" }, + { src = "src-ui", target = "path/to/src-ui" }, + { src = "src-ui/assets/*", target = "public" }, +] +icons = [ + "icons/32x32.png", + "icons/128x128.png", + "icons/128x128@2x.png", + "icons/icon.icns", + "icons/icon.ico", +] + +[package.metadata.packager.deb] +depends = ["libgtk-3-0", "libwebkit2gtk-4.1-0", "libayatana-appindicator3-1"] + +[package.metadata.packager.appimage] +bins = ["/usr/bin/xdg-open"] +libs = [ + "WebKitNetworkProcess", + "WebKitWebProcess", + "libwebkit2gtkinjectedbundle.so", + "libayatana-appindicator3.so.1", +] + +[package.metadata.packager.appimage.linuxdeploy-plugins] +"gtk" = "https://raw.githubusercontent.com/tauri-apps/linuxdeploy-plugin-gtk/master/linuxdeploy-plugin-gtk.sh" + +[package.metadata.packager.nsis] +appdata-paths = ["$LOCALAPPDATA/$IDENTIFIER"] +preinstall-section = """ +; Setup messages +; English +LangString webview2AbortError ${LANG_ENGLISH} "Failed to install WebView2! The app can't run without it. Try restarting the installer." +LangString webview2DownloadError ${LANG_ENGLISH} "Error: Downloading WebView2 Failed - $0" +LangString webview2DownloadSuccess ${LANG_ENGLISH} "WebView2 bootstrapper downloaded successfully" +LangString webview2Downloading ${LANG_ENGLISH} "Downloading WebView2 bootstrapper..." +LangString webview2InstallError ${LANG_ENGLISH} "Error: Installing WebView2 failed with exit code $1" +LangString webview2InstallSuccess ${LANG_ENGLISH} "WebView2 installed successfully" + +Section PreInstall + ; Check if Webview2 is already installed and skip this section + ${If} ${RunningX64} + ReadRegStr $4 HKLM "SOFTWARE\\WOW6432Node\\Microsoft\\EdgeUpdate\\Clients\\{F3017226-FE2A-4295-8BDF-00C3A9A7E4C5}" "pv" + ${Else} + ReadRegStr $4 HKLM "SOFTWARE\\Microsoft\\EdgeUpdate\\Clients\\{F3017226-FE2A-4295-8BDF-00C3A9A7E4C5}" "pv" + ${EndIf} + ReadRegStr $5 HKCU "SOFTWARE\\Microsoft\\EdgeUpdate\\Clients\\{F3017226-FE2A-4295-8BDF-00C3A9A7E4C5}" "pv" + + StrCmp $4 "" 0 webview2_done + StrCmp $5 "" 0 webview2_done + + Delete "$TEMP\\MicrosoftEdgeWebview2Setup.exe" + DetailPrint "$(webview2Downloading)" + nsis_tauri_utils::download "https://go.microsoft.com/fwlink/p/?LinkId=2124703" "$TEMP\\MicrosoftEdgeWebview2Setup.exe" + Pop $0 + ${If} $0 == 0 + DetailPrint "$(webview2DownloadSuccess)" + ${Else} + DetailPrint "$(webview2DownloadError)" + Abort "$(webview2AbortError)" + ${EndIf} + StrCpy $6 "$TEMP\\MicrosoftEdgeWebview2Setup.exe" + + DetailPrint "$(installingWebview2)" + ; $6 holds the path to the webview2 installer + ExecWait "$6 /install" $1 + ${If} $1 == 0 + DetailPrint "$(webview2InstallSuccess)" + ${Else} + DetailPrint "$(webview2InstallError)" + Abort "$(webview2AbortError)" + ${EndIf} + webview2_done: +SectionEnd +""" diff --git a/examples/tauri-with-updater/README.md b/examples/tauri-with-updater/README.md new file mode 100644 index 00000000..a6cf3db0 --- /dev/null +++ b/examples/tauri-with-updater/README.md @@ -0,0 +1,19 @@ +## Tauri example + +1. install `tauri-cli` first + + ```sh + cargo install tauri-cli --version "2.0.0-alpha.10" --locked + ``` + +2. Change `UPDATER_ENDPOINT` value in `src/main.rs` to point to your updater server or static update file. +3. package the app + + ```sh + cargo r -p cargo-packager -- -p tauri-example-with-updater --release --private-key dummy.key --password "" + ``` + +4. increase the version in `Cargo.toml` +5. do step 3 again +6. upload the resulting package from step 5 to your endpoint +7. run the app generated from step 3 diff --git a/examples/tauri-with-updater/build.rs b/examples/tauri-with-updater/build.rs new file mode 100644 index 00000000..d860e1e6 --- /dev/null +++ b/examples/tauri-with-updater/build.rs @@ -0,0 +1,3 @@ +fn main() { + tauri_build::build() +} diff --git a/examples/tauri-with-updater/dummy.key b/examples/tauri-with-updater/dummy.key new file mode 100644 index 00000000..c45525c5 --- /dev/null +++ b/examples/tauri-with-updater/dummy.key @@ -0,0 +1 @@ +dW50cnVzdGVkIGNvbW1lbnQ6IHJzaWduIGVuY3J5cHRlZCBzZWNyZXQga2V5ClJXUlRZMEl5VU1qSHBMT0E4R0JCVGZzbUMzb3ZXeGpGY1NSdm9OaUxaVTFuajd0T2ZKZ0FBQkFBQUFBQUFBQUFBQUlBQUFBQWlhRnNPUmxKWjBiWnJ6M29Cd0RwOUpqTW1yOFFQK3JTOGdKSi9CajlHZktHajI2ZnprbEM0VUl2MHhGdFdkZWpHc1BpTlJWK2hOTWo0UVZDemMvaFlYVUM4U2twRW9WV1JHenNzUkRKT2RXQ1FCeXlkYUwxelhacmtxOGZJOG1Nb1R6b0VEcWFLVUk9Cg== \ No newline at end of file diff --git a/examples/tauri-with-updater/dummy.key.pub b/examples/tauri-with-updater/dummy.key.pub new file mode 100644 index 00000000..cea27f94 --- /dev/null +++ b/examples/tauri-with-updater/dummy.key.pub @@ -0,0 +1 @@ +dW50cnVzdGVkIGNvbW1lbnQ6IG1pbmlzaWduIHB1YmxpYyBrZXk6IDQ2Njc0OTE5Mzk2Q0ExODkKUldTSm9XdzVHVWxuUmtJdjB4RnRXZGVqR3NQaU5SVitoTk1qNFFWQ3pjL2hZWFVDOFNrcEVvVlcK \ No newline at end of file diff --git a/examples/tauri-with-updater/icons/128x128.png b/examples/tauri-with-updater/icons/128x128.png new file mode 100644 index 00000000..6be5e50e Binary files /dev/null and b/examples/tauri-with-updater/icons/128x128.png differ diff --git a/examples/tauri-with-updater/icons/128x128@2x.png b/examples/tauri-with-updater/icons/128x128@2x.png new file mode 100644 index 00000000..e81becee Binary files /dev/null and b/examples/tauri-with-updater/icons/128x128@2x.png differ diff --git a/examples/tauri-with-updater/icons/32x32.png b/examples/tauri-with-updater/icons/32x32.png new file mode 100644 index 00000000..a437dd51 Binary files /dev/null and b/examples/tauri-with-updater/icons/32x32.png differ diff --git a/examples/tauri-with-updater/icons/Square107x107Logo.png b/examples/tauri-with-updater/icons/Square107x107Logo.png new file mode 100644 index 00000000..0ca4f271 Binary files /dev/null and b/examples/tauri-with-updater/icons/Square107x107Logo.png differ diff --git a/examples/tauri-with-updater/icons/Square142x142Logo.png b/examples/tauri-with-updater/icons/Square142x142Logo.png new file mode 100644 index 00000000..b81f8203 Binary files /dev/null and b/examples/tauri-with-updater/icons/Square142x142Logo.png differ diff --git a/examples/tauri-with-updater/icons/Square150x150Logo.png b/examples/tauri-with-updater/icons/Square150x150Logo.png new file mode 100644 index 00000000..624c7bfb Binary files /dev/null and b/examples/tauri-with-updater/icons/Square150x150Logo.png differ diff --git a/examples/tauri-with-updater/icons/Square284x284Logo.png b/examples/tauri-with-updater/icons/Square284x284Logo.png new file mode 100644 index 00000000..c021d2ba Binary files /dev/null and b/examples/tauri-with-updater/icons/Square284x284Logo.png differ diff --git a/examples/tauri-with-updater/icons/Square30x30Logo.png b/examples/tauri-with-updater/icons/Square30x30Logo.png new file mode 100644 index 00000000..62197002 Binary files /dev/null and b/examples/tauri-with-updater/icons/Square30x30Logo.png differ diff --git a/examples/tauri-with-updater/icons/Square310x310Logo.png b/examples/tauri-with-updater/icons/Square310x310Logo.png new file mode 100644 index 00000000..f9bc0483 Binary files /dev/null and b/examples/tauri-with-updater/icons/Square310x310Logo.png differ diff --git a/examples/tauri-with-updater/icons/Square44x44Logo.png b/examples/tauri-with-updater/icons/Square44x44Logo.png new file mode 100644 index 00000000..d5fbfb2a Binary files /dev/null and b/examples/tauri-with-updater/icons/Square44x44Logo.png differ diff --git a/examples/tauri-with-updater/icons/Square71x71Logo.png b/examples/tauri-with-updater/icons/Square71x71Logo.png new file mode 100644 index 00000000..63440d79 Binary files /dev/null and b/examples/tauri-with-updater/icons/Square71x71Logo.png differ diff --git a/examples/tauri-with-updater/icons/Square89x89Logo.png b/examples/tauri-with-updater/icons/Square89x89Logo.png new file mode 100644 index 00000000..f3f705af Binary files /dev/null and b/examples/tauri-with-updater/icons/Square89x89Logo.png differ diff --git a/examples/tauri-with-updater/icons/StoreLogo.png b/examples/tauri-with-updater/icons/StoreLogo.png new file mode 100644 index 00000000..45563882 Binary files /dev/null and b/examples/tauri-with-updater/icons/StoreLogo.png differ diff --git a/examples/tauri-with-updater/icons/icon.icns b/examples/tauri-with-updater/icons/icon.icns new file mode 100644 index 00000000..12a5bcee Binary files /dev/null and b/examples/tauri-with-updater/icons/icon.icns differ diff --git a/examples/tauri-with-updater/icons/icon.ico b/examples/tauri-with-updater/icons/icon.ico new file mode 100644 index 00000000..b3636e4b Binary files /dev/null and b/examples/tauri-with-updater/icons/icon.ico differ diff --git a/examples/tauri-with-updater/icons/icon.png b/examples/tauri-with-updater/icons/icon.png new file mode 100644 index 00000000..e1cd2619 Binary files /dev/null and b/examples/tauri-with-updater/icons/icon.png differ diff --git a/examples/tauri-with-updater/src-ui/index.html b/examples/tauri-with-updater/src-ui/index.html new file mode 100644 index 00000000..5d8a62fa --- /dev/null +++ b/examples/tauri-with-updater/src-ui/index.html @@ -0,0 +1,14 @@ + + + + + + + Tauri App + + + + +
+ + diff --git a/examples/tauri-with-updater/src-ui/main.js b/examples/tauri-with-updater/src-ui/main.js new file mode 100644 index 00000000..3490e769 --- /dev/null +++ b/examples/tauri-with-updater/src-ui/main.js @@ -0,0 +1,96 @@ +import { + createApp, + ref, + onMounted, + onUnmounted, + computed, +} from "https://unpkg.com/vue@3/dist/vue.esm-browser.prod.js"; +const { invoke } = window.__TAURI__; +const { listen } = window.__TAURI__.event; + +createApp({ + setup() { + const version = ref(""); + const updateStatus = ref("unchecked"); // variants: "unchecked" | "has-update" | "no-updates" | "downloading" | "ready-for-install" | "installing" + const updateContentLen = ref(0); + const updateDownloadedDataLen = ref(0); + const updateProgress = ref(0); + const updateVersion = ref(""); + const checkBtnDisabled = computed( + () => + updateStatus.value === "has-update" || + updateStatus.value == "downloading" || + updateStatus.value === "ready-for-install" + ); + + async function checkUpdate() { + const [hasUpdate, version] = await invoke("check_update"); + if (version) updateVersion.value = version; + updateStatus.value = hasUpdate ? "has-update" : "no-updates"; + } + + async function downloadUpdate() { + updateStatus.value = "downloading"; + await invoke("download_update"); + updateStatus.value = "ready-for-install"; + } + + async function installUpdate() { + await invoke("install_update"); + } + + let removeProgressListener; + + onMounted(async () => { + version.value = await invoke("version"); + + removeProgressListener = await listen("update_progress", (event) => { + const { chunk_len, content_len } = event.payload; + if (content_len) { + updateContentLen.value = content_len; + } + + updateDownloadedDataLen.value = + updateDownloadedDataLen.value + chunk_len; + + updateProgress.value = + (updateDownloadedDataLen.value / updateContentLen.value) * 100; + }); + }); + + onUnmounted(() => removeProgressListener()); + + return { + version, + updateStatus, + updateVersion, + updateContentLen, + updateDownloadedDataLen, + updateProgress, + checkBtnDisabled, + checkUpdate, + downloadUpdate, + installUpdate, + }; + }, + template: ` +

appVersion: {{version}}

+ + + + `, +}).mount("#app"); diff --git a/examples/tauri-with-updater/src-ui/styles.css b/examples/tauri-with-updater/src-ui/styles.css new file mode 100644 index 00000000..f249476a --- /dev/null +++ b/examples/tauri-with-updater/src-ui/styles.css @@ -0,0 +1,131 @@ +:root { + font-family: Inter, Avenir, Helvetica, Arial, sans-serif; + font-size: 16px; + line-height: 24px; + font-weight: 400; + + color: #0f0f0f; + background-color: #f6f6f6; + + font-synthesis: none; + text-rendering: optimizeLegibility; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + -webkit-text-size-adjust: 100%; +} + +.container { + margin: 0; + padding-top: 10vh; + display: flex; + flex-direction: column; + justify-content: center; + text-align: center; +} + +.logo { + height: 6em; + padding: 1.5em; + will-change: filter; + transition: 0.75s; +} + +.logo.tauri:hover { + filter: drop-shadow(0 0 2em #24c8db); +} + +.row { + display: flex; +} + +a { + font-weight: 500; + color: #646cff; + text-decoration: inherit; +} + +a:hover { + color: #535bf2; +} + +h1 { + text-align: center; +} + +input, +button { + border-radius: 8px; + border: 1px solid transparent; + padding: 0.6em 1.2em; + font-size: 1em; + font-weight: 500; + font-family: inherit; + color: #0f0f0f; + background-color: #ffffff; + transition: border-color 0.25s; + box-shadow: 0 2px 2px rgba(0, 0, 0, 0.2); +} + +button { + cursor: pointer; +} + +button:hover { + border-color: #396cd8; +} + +button[disabled] { + background-color: #dfdfdf; + cursor: unset; +} +button[disabled]:hover { + border-color: transparent; +} + +input, +button { + outline: none; +} + +#greet-input { + margin-right: 5px; +} + +code { + background-color: #e0e0e0db; + padding: 8px; + border-radius: 5px; +} + +@media (prefers-color-scheme: dark) { + :root { + color: #f6f6f6; + background-color: #2f2f2f; + } + + a:hover { + color: #24c8db; + } + + input, + button { + color: #ffffff; + background-color: #0f0f0f98; + } + + button[disabled] { + color: #8c8c8c; + background-color: #0f0f0f38; + } + button:active, + button[disabled]:active { + background-color: #0f0f0f69; + } + code { + background-color: #18181879; + } +} + +.vcenter { + align-items: center; +} diff --git a/examples/tauri-with-updater/src/main.rs b/examples/tauri-with-updater/src/main.rs new file mode 100644 index 00000000..632f8d8e --- /dev/null +++ b/examples/tauri-with-updater/src/main.rs @@ -0,0 +1,102 @@ +// Prevents additional console window on Windows in release, DO NOT REMOVE!! +#![cfg_attr(not(debug_assertions), windows_subsystem = "windows")] + +use cargo_packager_updater::{Config, Update, UpdaterBuilder}; +use tauri::{AppHandle, Manager, Runtime}; + +// Learn more about Tauri commands at https://tauri.app/v1/guides/features/command +#[tauri::command] +fn version() -> &'static str { + env!("CARGO_PKG_VERSION") +} + +const UPDATER_PUB_KEY: &str = include_str!("../dummy.key.pub"); +const UPDATER_ENDPOINT: &str = "http://localhost:2342"; + +#[tauri::command] +fn check_update(app: AppHandle) -> Result<(bool, Option), ()> { + let config = Config { + pubkey: UPDATER_PUB_KEY.into(), + endpoints: vec![UPDATER_ENDPOINT.parse().unwrap()], + ..Default::default() + }; + + let updater = { + #[allow(unused_mut)] + let mut updater_builder = UpdaterBuilder::new(app.package_info().version.clone(), config); + #[cfg(any( + target_os = "linux", + target_os = "dragonfly", + target_os = "freebsd", + target_os = "netbsd", + target_os = "openbsd" + ))] + { + if let Some(appimage) = app.env().appimage { + updater_builder = updater_builder.executable_path(appimage) + } + } + updater_builder.build().unwrap() + }; + + let update = updater.check().unwrap(); + let has_update = update.is_some(); + let version = update.as_ref().map(|u| u.version.clone()); + if let Some(update) = update { + app.manage(update); + } + + Ok((has_update, version)) +} + +struct UpdateBytes(Vec); + +#[derive(serde::Serialize, Clone)] +struct ProgressPayload { + chunk_len: usize, + content_len: Option, +} +#[tauri::command] +fn download_update(app: AppHandle) -> Result<(), ()> { + let app_1 = app.clone(); + std::thread::spawn(move || { + let update = app.state::(); + let update_bytes = update + .download( + move |chunk_len, content_len| { + app_1 + .emit_all( + "update_progress", + ProgressPayload { + chunk_len, + content_len, + }, + ) + .unwrap(); + }, + move || {}, + ) + .unwrap(); + app.manage(UpdateBytes(update_bytes)); + }); + Ok(()) +} +#[tauri::command] +fn install_update(app: AppHandle) -> Result<(), ()> { + let update = app.state::(); + let update_bytes = app.state::(); + update.install(update_bytes.0.clone()).unwrap(); + Ok(()) +} + +fn main() { + tauri::Builder::default() + .invoke_handler(tauri::generate_handler![ + version, + check_update, + download_update, + install_update + ]) + .run(tauri::generate_context!()) + .expect("error while running tauri application"); +} diff --git a/examples/tauri-with-updater/tauri.conf.json b/examples/tauri-with-updater/tauri.conf.json new file mode 100644 index 00000000..f774fd6c --- /dev/null +++ b/examples/tauri-with-updater/tauri.conf.json @@ -0,0 +1,42 @@ +{ + "build": { + "beforeDevCommand": "", + "beforeBuildCommand": "", + "devPath": "./src-ui", + "distDir": "./src-ui", + "withGlobalTauri": true + }, + "package": { + "productName": "tauri-example-with-updater", + "version": "0.0.1" + }, + "tauri": { + "bundle": { + "active": false, + "targets": "all", + "identifier": "com.tauri-with-updater.example", + "icon": [ + "icons/32x32.png", + "icons/128x128.png", + "icons/128x128@2x.png", + "icons/icon.icns", + "icons/icon.ico" + ] + }, + "security": { + "csp": null, + "dangerousRemoteDomainIpcAccess": [ + { "domain": "tauri.localhost", "windows": ["main"] } + ] + }, + "windows": [ + { + "fullscreen": false, + "resizable": true, + "title": "tauri", + "width": 800, + "height": 600 + } + ] + } +} diff --git a/examples/wails/Packager.toml b/examples/wails/Packager.toml index 80be6aaa..21749e20 100644 --- a/examples/wails/Packager.toml +++ b/examples/wails/Packager.toml @@ -6,7 +6,7 @@ product-name = "Wails example" identifier = "com.wails.example" resources = ["Cargo.toml", "src", "32x32.png"] icons = ["32x32.png"] -binaries = [{ filename = "wails_example", main = true }] +binaries = [{ path = "wails_example", main = true }] [deb] depends = ["libgtk-3-0", "libwebkit2gtk-4.1-0"]