}
#[tokio::main]
-async fn main() -> Result<(), AE> {
- dedup_eyre_setup()?;
- let opts = Opts::from_args();
+async fn main() {
+ let (ics,) =(||{
+ dedup_eyre_setup()?;
+ let opts = Opts::from_args();
- let ics = config::read(&opts.config, LinkEnd::Client)?;
- if ics.is_empty() { throw!(anyhow!("no associations with server(s)")); }
+ let ics = config::read(&opts.config, LinkEnd::Client)?;
+ if ics.is_empty() { throw!(anyhow!("no associations with server(s)")); }
- opts.log.log_init()?;
+ opts.log.log_init()?;
+
+ Ok::<_,AE>((ics,))
+ })().unwrap_or_else(|e| {
+ eprintln!("hippotat: startup error: {}", &e);
+ process::exit(8);
+ });
let https = HttpsConnector::new();
let hclient = hyper::Client::builder().build::<_, hyper::Body>(https);