summaryrefslogtreecommitdiff
path: root/server/src/main.rs
diff options
context:
space:
mode:
Diffstat (limited to 'server/src/main.rs')
-rw-r--r--server/src/main.rs11
1 files changed, 10 insertions, 1 deletions
diff --git a/server/src/main.rs b/server/src/main.rs
index 5bd8b28..d375060 100644
--- a/server/src/main.rs
+++ b/server/src/main.rs
@@ -1,6 +1,15 @@
// Copyright 2022-2024 Gabriel Bjørnager Jensen.
use bowshock::use_mod;
+use_mod!(pub config);
+use_mod!(pub error);
use_mod!(pub server);
+use_mod!(pub session);
-fn main() -> Result<(), i32> { Server::new().run() }
+fn main() -> Result<()> {
+ let config = Config::load()?;
+ let result = Server::new(config).run();
+
+ if let Err(ref e) = result { eprintln!("unable to run server: {e}"); }
+ result
+}