ref(example_cli): Add new struct Init

for holding the items returned from `example_cli::init`
This commit is contained in:
vmammal
2024-01-30 17:56:51 -05:00
parent 89a7ddca7f
commit 1c15cb2f91
4 changed files with 42 additions and 19 deletions

View File

@@ -110,9 +110,13 @@ enum RpcCommands {
fn main() -> anyhow::Result<()> {
let start = Instant::now();
let (args, keymap, index, db, init_changeset) =
example_cli::init::<RpcCommands, RpcArgs, ChangeSet>(DB_MAGIC, DB_PATH)?;
let example_cli::Init {
args,
keymap,
index,
db,
init_changeset,
} = example_cli::init::<RpcCommands, RpcArgs, ChangeSet>(DB_MAGIC, DB_PATH)?;
println!(
"[{:>10}s] loaded initial changeset from db",
start.elapsed().as_secs_f32()