feat: add server-only build
it's drastically faster to build, mostly due to only including 1/10th of the dependencies
This commit is contained in:
parent
e310ca570b
commit
1546c67fa3
3 changed files with 24 additions and 4 deletions
|
|
@ -1,5 +1,6 @@
|
|||
use std::env;
|
||||
|
||||
#[cfg(feature = "app")]
|
||||
mod app;
|
||||
mod server;
|
||||
mod sysinfo_snapshot;
|
||||
|
|
@ -7,10 +8,12 @@ mod utils;
|
|||
|
||||
fn main() {
|
||||
match env::args().nth(1).as_deref() {
|
||||
Some("server") => server::run().unwrap(),
|
||||
|
||||
#[cfg(feature = "app")]
|
||||
None | Some("client") => app::run().unwrap(),
|
||||
|
||||
#[cfg_attr(feature = "app", allow(unreachable_patterns))]
|
||||
None | Some("server") => server::run().unwrap(),
|
||||
|
||||
Some(s) => panic!("invalid argument: {s}"),
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue