plugins-workspace
plugins-workspace copied to clipboard
[V1 single-instance]: Both projects, both using the single-instance plugin, cannot be started at the same time
The tauri v1 version used on Windows11.
main.rs :
use tauri::{Manager};
#[derive(Clone, serde::Serialize)]
struct Payload {
args: Vec<String>,
cwd: String,
}
fn main() {
tauri::Builder::default()
.plugin(tauri_plugin_single_instance::init(|app, argv, cwd| {
println!("{}, {argv:?}, {cwd}", app.package_info().name);
app.emit_all("single-instance", Payload { args: argv, cwd }).unwrap();
}))
.setup(|app| {
set_window_shadow(app);
Ok(())
})
.run(tauri::generate_context!())
.expect("error while running tauri application");
}
Do I need to modify some configurations?
I think this will help you.
Pass: changeme If you don't have the c compliator, install it.(gcc or clang)
This plugin uses the identifier set in tauri.conf.json to identify the related app instances. Are they the same for both of your apps?
This plugin uses the
identifierset in tauri.conf.json to identify the related app instances. Are they the same for both of your apps?
Took a look at it, and it does, thank you