first commit

This commit is contained in:
2026-05-18 22:32:23 +02:00
commit 2cf50b0168
10 changed files with 2045 additions and 0 deletions
+19
View File
@@ -0,0 +1,19 @@
use dotenvy::dotenv;
pub struct EnvConfig {
pub http_port: u16,
pub bot_name: String,
}
pub fn load_config() -> anyhow::Result<EnvConfig> {
dotenv().ok();
let http_port = std::env::var("HTTP_PORT")?.parse()?;
let bot_name = std::env::var("BOT_NAME")?;
Ok(EnvConfig {
http_port,
bot_name,
})
}