Adapt code from iganaq
This commit is contained in:
parent
4053c354bd
commit
ca20c11962
60 changed files with 1329 additions and 1860 deletions
15
src/main.rs
Normal file
15
src/main.rs
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
use tori::{conf, log, run, state};
|
||||
|
||||
fn main() -> std::process::ExitCode {
|
||||
log::elog(&format!("tori {}", env!("CARGO_PKG_VERSION")));
|
||||
let configuration = conf::load();
|
||||
log::elog(&format!("Configuration: {configuration:#?}"));
|
||||
let order = run::teller::parse(std::env::args(), &configuration);
|
||||
log::elog(&format!("Order: {order:#?}"));
|
||||
let state = state::setup(&configuration, &[order]);
|
||||
log::elog(&format!("State: {state:#?}"));
|
||||
let result = run::expeditor::fulfill(&state);
|
||||
log::elog(&format!("Filled Order: {result:#?}"));
|
||||
|
||||
if result.is_ok() { 0.into() } else { 1.into() }
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue