mirror of
https://github.com/watchexec/watchexec.git
synced 2024-10-02 08:01:34 +02:00
23 lines
484 B
Rust
23 lines
484 B
Rust
#[cfg(feature = "eyra")]
|
|
extern crate eyra;
|
|
|
|
use miette::IntoDiagnostic;
|
|
|
|
#[cfg(target_env = "musl")]
|
|
#[global_allocator]
|
|
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
|
|
|
|
fn main() -> miette::Result<()> {
|
|
#[cfg(feature = "pid1")]
|
|
pid1::Pid1Settings::new()
|
|
.enable_log(cfg!(feature = "pid1-withlog"))
|
|
.launch()
|
|
.into_diagnostic()?;
|
|
|
|
tokio::runtime::Builder::new_multi_thread()
|
|
.enable_all()
|
|
.build()
|
|
.unwrap()
|
|
.block_on(async { watchexec_cli::run().await })
|
|
}
|