flamethrower 0.1.1

Deterministic cognition ledger using power_house (and optional pent_house).
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#[derive(Clone, Debug)]
pub struct Config {
    pub port: u16,
    pub ledger_path: String,
}

impl Config {
    pub fn from_env() -> Self {
        let port = std::env::var("FLAME_PORT")
            .ok()
            .and_then(|s| s.parse().ok())
            .unwrap_or(8080);
        let ledger_path = std::env::var("FLAME_LEDGER").unwrap_or_else(|_| "./ledger.db".into());
        Self { port, ledger_path }
    }
}