Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 17 additions & 16 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ members = ["crates/*", "apps/*", "xtask"]
# default-members

[workspace.package]
version = "2.0.1"
version = "2.0.2"
edition = "2024"
license = "MIT OR Apache-2.0"
rust-version = "1.95"
Expand Down
11 changes: 9 additions & 2 deletions apps/draftcraft/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,9 @@ fn main() -> eframe::Result {
let launch = launch_args::parse(launch_args::command(), std::env::args_os().skip(1)).unwrap_or_else(|e| e.exit());
let vars = env::Env::read();
adopt_old_folders(vars.config_dir.as_deref());
// What an in-app update left beside this copy (the old app, `*.old` files).
#[cfg(not(target_arch = "wasm32"))]
draftcraft_ui_egui::self_update::clean_leftovers();
let (control_port, sample, files) = (launch.control, launch.sample, launch.files);
// The log file lives under the settings directory; opened after the arguments, so `--version`
// leaves no file behind. Records logged until now are written to it first.
Expand Down Expand Up @@ -387,7 +390,7 @@ fn main() -> eframe::Result {
b.with_close_requested_on_terminate(true);
}));
}
eframe::run_native(
let result = eframe::run_native(
"DraftCraft",
options,
Box::new(move |cc| {
Expand Down Expand Up @@ -470,7 +473,11 @@ fn main() -> eframe::Result {
movable: None,
}))
}),
)
);
// Restart Now after an in-app update: the new copy starts once this window has closed.
#[cfg(not(target_arch = "wasm32"))]
draftcraft_ui_egui::self_update::relaunch_if_scheduled();
result
}

#[cfg(test)]
Expand Down
2 changes: 2 additions & 0 deletions crates/ui-egui/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ web-time = { workspace = true }

[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
craft-update = { workspace = true }
# Unpacks the Windows update zip (self_update.rs); the same version and features craft-update uses.
zip = { version = "9", default-features = false, features = ["deflate"] }

[dev-dependencies]
# Tests build the dock area as the desktop app does (headless contexts keep floats in-window).
Expand Down
16 changes: 16 additions & 0 deletions crates/ui-egui/src/i18n/it.tsv
Original file line number Diff line number Diff line change
Expand Up @@ -1386,6 +1386,22 @@ menu Modify Edita
Skip This Version Salta questa versione
DraftCraft is up to date (version {version}). DraftCraft è aggiornato (versione {version}).
Could not check for updates. Impossibile verificare gli aggiornamenti.
Do you want to install the update now? Vuoi installare l'aggiornamento adesso?
Update Now Aggiorna ora
Open the release page Apri la pagina della release
This copy of DraftCraft can't update itself. Questa copia di DraftCraft non può aggiornarsi da sola.
Updating DraftCraft Aggiornamento di DraftCraft
Update Failed Aggiornamento non riuscito
Installing DraftCraft {version} Installazione di DraftCraft {version}
Downloading: {done} of {total} MB Download: {done} di {total} MB
Installing… Installazione…
Starting the download… Avvio del download…
The connection dropped; trying again… Connessione interrotta; nuovo tentativo…
DraftCraft {version} is installed. DraftCraft {version} è installato.
Restart DraftCraft to use it. If you restart later, it opens the next time you start DraftCraft. Riavvia DraftCraft per usarlo. Se riavvii più tardi, si aprirà al prossimo avvio di DraftCraft.
Restart Now Riavvia ora
The update could not be installed. Impossibile installare l'aggiornamento.
You can download it from the release page instead. Puoi scaricarlo invece dalla pagina della release.
Find All Find All
Find what: Find what:
Match case Match case
Expand Down
16 changes: 16 additions & 0 deletions crates/ui-egui/src/i18n/zh.tsv
Original file line number Diff line number Diff line change
Expand Up @@ -1369,6 +1369,22 @@
Skip This Version 跳过此版本
DraftCraft is up to date (version {version}). DraftCraft 已是最新版本({version})。
Could not check for updates. 无法检查更新。
Do you want to install the update now? 要立即安装更新吗?
Update Now 立即更新
Open the release page 打开发布页面
This copy of DraftCraft can't update itself. 此 DraftCraft 副本无法自行更新。
Updating DraftCraft 正在更新 DraftCraft
Update Failed 更新失败
Installing DraftCraft {version} 正在安装 DraftCraft {version}
Downloading: {done} of {total} MB 正在下载:{done} / {total} MB
Installing… 正在安装…
Starting the download… 正在开始下载…
The connection dropped; trying again… 连接中断,正在重试…
DraftCraft {version} is installed. DraftCraft {version} 已安装。
Restart DraftCraft to use it. If you restart later, it opens the next time you start DraftCraft. 重新启动 DraftCraft 即可使用。如果稍后重启,下次启动 DraftCraft 时将打开新版本。
Restart Now 立即重启
The update could not be installed. 无法安装更新。
You can download it from the release page instead. 您也可以从发布页面下载。
# Menu and command labels the October 2026 update missed (#1129).
Align Multileaders 对齐多重引线
Analyze Usage 分析使用情况
Expand Down
2 changes: 2 additions & 0 deletions crates/ui-egui/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,8 @@ pub mod plotstyles;
pub mod quick;
pub mod ribbon;
pub mod save_loss;
#[cfg(not(target_arch = "wasm32"))]
pub mod self_update;
pub mod shortcut_menus;
pub mod theme;
#[cfg(not(target_arch = "wasm32"))]
Expand Down
Loading