mirror of
https://github.com/jamiepine/voicebox.git
synced 2026-09-16 21:30:39 -07:00
Implement autoupdater functionality and enhance icon management
- Added a new UpdateNotification component to inform users about available updates and facilitate installation. - Integrated useAutoUpdater hook for managing update checks and installations. - Updated package.json with new build and generate scripts for release preparation and key generation. - Enhanced tauri configuration to support autoupdater with signing keys and endpoints. - Created scripts for preparing signed releases and updating icons, ensuring a streamlined workflow for asset management. - Added detailed documentation for autoupdater setup and icon update workflow.
This commit is contained in:
+16
-13
@@ -132,6 +132,22 @@ pub fn run() {
|
||||
.manage(ServerState {
|
||||
child: Mutex::new(None),
|
||||
})
|
||||
.setup(|app| {
|
||||
#[cfg(desktop)]
|
||||
app.handle().plugin(tauri_plugin_updater::Builder::new().build())?;
|
||||
|
||||
#[cfg(debug_assertions)]
|
||||
{
|
||||
// Get all windows and open devtools on the first one
|
||||
if let Some((_, window)) = app.webview_windows().iter().next() {
|
||||
window.open_devtools();
|
||||
println!("Dev tools opened");
|
||||
} else {
|
||||
println!("No window found to open dev tools");
|
||||
}
|
||||
}
|
||||
Ok(())
|
||||
})
|
||||
.invoke_handler(tauri::generate_handler![start_server, stop_server])
|
||||
.on_window_event(|window, event| {
|
||||
if let WindowEvent::CloseRequested { api, .. } = event {
|
||||
@@ -177,19 +193,6 @@ pub fn run() {
|
||||
});
|
||||
}
|
||||
})
|
||||
.setup(|_app| {
|
||||
#[cfg(debug_assertions)]
|
||||
{
|
||||
// Get all windows and open devtools on the first one
|
||||
if let Some((_, window)) = _app.webview_windows().iter().next() {
|
||||
window.open_devtools();
|
||||
println!("Dev tools opened");
|
||||
} else {
|
||||
println!("No window found to open dev tools");
|
||||
}
|
||||
}
|
||||
Ok(())
|
||||
})
|
||||
.run(tauri::generate_context!())
|
||||
.expect("error while running tauri application");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user