use sled::{Db, IVec, Tree}; use std::path::Path; const DB_DIR: &'static str = "db"; pub struct Dbs { db: Db, } pub fn load_dbs(path: &Path) -> Dbs { //std::fs::create_dir_all(path.join(DB_DIR)).expect("Cannot create db dir"); let db = sled::open(path.join(DB_DIR)).expect("Cannot open db"); Dbs { db } }