--- a/crates/nix-native-eval/Cargo.toml +++ b/crates/nix-native-eval/Cargo.toml @@ -4,4 +4,5 @@ version.workspace = true [dependencies] +anyhow.workspace = true nixrs = { git = "https://github.com/Anillc/nixrs", version = "0.1.0" } --- a/crates/nix-native-eval/src/lib.rs +++ b/crates/nix-native-eval/src/lib.rs @@ -1,7 +1,11 @@ +use anyhow::Result; use nixrs::{State, Store}; -fn init() { - nixrs::init(); +pub fn init() -> Result<()> { + nixrs::init()?; let store = Store::new("daemon")?; - let state = State::new(store) + let state = State::new(store)?; + let _ = state; + + Ok(()) }