WIP: Start on auto-update
Co-Authored-By: Nathan Sobo <nathan@zed.dev> Co-Authored-By: Max Brunsfeld <max@zed.dev> Co-Authored-By: Keith Simmons <keith@zed.dev>
This commit is contained in:
parent
cbf6d827db
commit
38e902b241
8 changed files with 189 additions and 20 deletions
|
@ -19,7 +19,8 @@ use workspace::{
|
|||
AppState, OpenNew, OpenParams, OpenPaths, Settings,
|
||||
};
|
||||
use zed::{
|
||||
self, assets::Assets, build_window_options, build_workspace, fs::RealFs, languages, menus,
|
||||
self, assets::Assets, auto_updater::AutoUpdater, build_window_options, build_workspace,
|
||||
fs::RealFs, languages, menus,
|
||||
};
|
||||
|
||||
fn main() {
|
||||
|
@ -64,6 +65,13 @@ fn main() {
|
|||
let user_store = cx.add_model(|cx| UserStore::new(client.clone(), http.clone(), cx));
|
||||
let channel_list =
|
||||
cx.add_model(|cx| ChannelList::new(user_store.clone(), client.clone(), cx));
|
||||
let auto_updater = if let Ok(current_version) = cx.platform().app_version() {
|
||||
Some(cx.add_model(|cx| {
|
||||
AutoUpdater::new(current_version, http, client::ZED_SERVER_URL.clone())
|
||||
}))
|
||||
} else {
|
||||
None
|
||||
};
|
||||
|
||||
project::Project::init(&client);
|
||||
client::Channel::init(&client);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue