diff --git a/Cargo.lock b/Cargo.lock index e817c0e..29aa5a6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -815,40 +815,6 @@ dependencies = [ "wayland-client", ] -[[package]] -name = "cargo-packager-updater" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b60a6cdf300a0f0ee62f3f435e23cc97ef7a0a3a489a3aee6b0ca0cd986d722b" -dependencies = [ - "base64", - "cargo-packager-utils", - "ctor 0.2.9", - "dirs 5.0.1", - "dunce", - "flate2", - "http", - "minisign-verify", - "reqwest 0.12.12", - "semver", - "serde", - "serde_json", - "tar", - "tempfile", - "thiserror 1.0.69", - "time", - "url", -] - -[[package]] -name = "cargo-packager-utils" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b43458dd2ee3cdab3f5b105acd80791383b730380c929018701313d7d299d4e8" -dependencies = [ - "ctor 0.2.9", -] - [[package]] name = "cbc" version = "0.1.2" @@ -1208,7 +1174,6 @@ name = "coop" version = "0.1.1" dependencies = [ "anyhow", - "cargo-packager-updater", "chats", "common", "dirs 5.0.1", @@ -1406,16 +1371,6 @@ dependencies = [ "typenum", ] -[[package]] -name = "ctor" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32a2785755761f3ddc1492979ce1e48d2c00d09311c39e4466429188f3dd6501" -dependencies = [ - "quote", - "syn 2.0.98", -] - [[package]] name = "ctor" version = "0.3.3" @@ -1434,15 +1389,6 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5c297a1c74b71ae29df00c3e22dd9534821d60eb9af5a0192823fa2acea70c2a" -[[package]] -name = "deranged" -version = "0.3.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b42b6fa04a440b495c8b04d0e71b707c585f83cb9cb28cf8cd0d976c315e31b4" -dependencies = [ - "powerfmt", -] - [[package]] name = "derive_more" version = "0.99.19" @@ -1749,18 +1695,6 @@ dependencies = [ "winapi", ] -[[package]] -name = "filetime" -version = "0.2.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c0522e981e68cbfa8c3f978441a5f34b30b96e146b33cd3359176b50fe8586" -dependencies = [ - "cfg-if", - "libc", - "libredox", - "windows-sys 0.59.0", -] - [[package]] name = "flatbuffers" version = "23.5.26" @@ -2212,7 +2146,7 @@ dependencies = [ "core-graphics 0.23.2", "core-text", "cosmic-text", - "ctor 0.3.3", + "ctor", "derive_more", "embed-resource", "etagere", @@ -3037,7 +2971,6 @@ checksum = "c0ff37bd590ca25063e35af745c343cb7a0271906fb7b37e4813e8f79f00268d" dependencies = [ "bitflags 2.8.0", "libc", - "redox_syscall", ] [[package]] @@ -3193,7 +3126,7 @@ dependencies = [ "anyhow", "bindgen 0.70.1", "core-foundation 0.9.4", - "ctor 0.3.3", + "ctor", "foreign-types", "metal", "objc", @@ -3260,12 +3193,6 @@ version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" -[[package]] -name = "minisign-verify" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6367d84fb54d4242af283086402907277715b8fe46976963af5ebf173f8efba3" - [[package]] name = "miniz_oxide" version = "0.8.4" @@ -3526,12 +3453,6 @@ dependencies = [ "num-traits", ] -[[package]] -name = "num-conv" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51d515d32fb182ee37cda2ccdcb92950d6a3c2893aa280e540671c2cd0f3b1d9" - [[package]] name = "num-derive" version = "0.4.2" @@ -4153,12 +4074,6 @@ dependencies = [ "thiserror 1.0.69", ] -[[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.20" @@ -4580,7 +4495,6 @@ checksum = "43e734407157c3c2034e0258f5e4473ddb361b1e85f95a66690d67264d7cd1da" dependencies = [ "base64", "bytes", - "futures-channel", "futures-core", "futures-util", "http", @@ -4599,7 +4513,6 @@ dependencies = [ "pin-project-lite", "quinn", "rustls", - "rustls-native-certs", "rustls-pemfile", "rustls-pki-types", "serde", @@ -4609,13 +4522,11 @@ dependencies = [ "tokio", "tokio-rustls", "tokio-socks", - "tokio-util", "tower", "tower-service", "url", "wasm-bindgen", "wasm-bindgen-futures", - "wasm-streams", "web-sys", "webpki-roots", "windows-registry", @@ -5553,17 +5464,6 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8bdb6fa0dfa67b38c1e66b7041ba9dcf23b99d8121907cd31c807a332f7a0bbb" -[[package]] -name = "tar" -version = "0.4.43" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c65998313f8e17d0d553d28f91a0df93e4dbbbf770279c7bc21ca0f09ea1a1f6" -dependencies = [ - "filetime", - "libc", - "xattr", -] - [[package]] name = "target-lexicon" version = "0.12.16" @@ -5665,37 +5565,6 @@ dependencies = [ "weezl", ] -[[package]] -name = "time" -version = "0.3.37" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35e7868883861bd0e56d9ac6efcaaca0d6d5d82a2a7ec8209ff492c07cf37b21" -dependencies = [ - "deranged", - "itoa", - "num-conv", - "powerfmt", - "serde", - "time-core", - "time-macros", -] - -[[package]] -name = "time-core" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3" - -[[package]] -name = "time-macros" -version = "0.2.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2834e6017e3e5e4b9834939793b282bc03b37a3336245fa820e35e233e2a85de" -dependencies = [ - "num-conv", - "time-core", -] - [[package]] name = "tiny-keccak" version = "2.0.2" @@ -6989,17 +6858,6 @@ version = "0.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec107c4503ea0b4a98ef47356329af139c0a4f7750e621cf2973cd3385ebcb3d" -[[package]] -name = "xattr" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e105d177a3871454f754b33bb0ee637ecaaac997446375fd3e5d43a2ed00c909" -dependencies = [ - "libc", - "linux-raw-sys", - "rustix", -] - [[package]] name = "xcursor" version = "0.3.8" diff --git a/crates/app/Cargo.toml b/crates/app/Cargo.toml index dc4ec49..3aad385 100644 --- a/crates/app/Cargo.toml +++ b/crates/app/Cargo.toml @@ -29,6 +29,5 @@ rust-embed.workspace = true smol.workspace = true rustls = "0.23.23" -cargo-packager-updater = "0.2.2" tracing-subscriber = { version = "0.3.18", features = ["fmt"] } log = "0.4" diff --git a/crates/app/src/views/app.rs b/crates/app/src/views/app.rs index 578faf4..8df435e 100644 --- a/crates/app/src/views/app.rs +++ b/crates/app/src/views/app.rs @@ -1,14 +1,9 @@ -use cargo_packager_updater::{check_update, semver::Version, url::Url}; -use common::{ - constants::{UPDATER_PUBKEY, UPDATER_URL}, - profile::NostrProfile, -}; +use common::profile::NostrProfile; use gpui::{ actions, div, img, impl_internal_actions, prelude::FluentBuilder, px, App, AppContext, Axis, Context, Entity, InteractiveElement, IntoElement, ObjectFit, ParentElement, Render, Styled, StyledImage, Window, }; -use log::info; use nostr_sdk::prelude::*; use serde::Deserialize; use state::get_client; @@ -88,26 +83,6 @@ impl AppView { view.set_center(center_panel, window, cx); }); - // Check and auto update to the latest version - cx.background_spawn(async move { - // Set auto updater config - let config = cargo_packager_updater::Config { - endpoints: vec![Url::parse(UPDATER_URL).expect("Failed to parse UPDATER URL")], - pubkey: String::from(UPDATER_PUBKEY), - ..Default::default() - }; - - // Run auto updater - if let Ok(current_version) = Version::parse(env!("CARGO_PKG_VERSION")) { - if let Ok(Some(update)) = check_update(current_version, config) { - if update.download_and_install().is_ok() { - info!("Update installed") - } - } - } - }) - .detach(); - cx.new(|cx| { let public_key = account.public_key(); let relays = cx.new(|_| None);