mirror of
https://github.com/jackwener/wx-cli.git
synced 2026-10-08 05:25:45 +00:00
chore: gate unix-only daemon helpers
This commit is contained in:
@@ -8,6 +8,7 @@ use crate::config;
|
|||||||
use crate::ipc::{Request, Response};
|
use crate::ipc::{Request, Response};
|
||||||
|
|
||||||
const STARTUP_TIMEOUT_SECS: u64 = 15;
|
const STARTUP_TIMEOUT_SECS: u64 = 15;
|
||||||
|
#[cfg(unix)]
|
||||||
const STOP_TIMEOUT_MS: u64 = 2_000;
|
const STOP_TIMEOUT_MS: u64 = 2_000;
|
||||||
|
|
||||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||||
|
|||||||
@@ -138,6 +138,7 @@ async fn setup_signal_handler() {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[cfg(unix)]
|
||||||
fn cleanup_and_exit() {
|
fn cleanup_and_exit() {
|
||||||
cleanup_ipc_files();
|
cleanup_ipc_files();
|
||||||
std::process::exit(0);
|
std::process::exit(0);
|
||||||
|
|||||||
Reference in New Issue
Block a user