Add sqlite connection call
And make main() async
This commit is contained in:
parent
55c549d2cf
commit
96c6d14c46
@ -40,7 +40,8 @@ impl Default for Config {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fn main() -> Result<(), Box<dyn Error>> {
|
#[tokio::main]
|
||||||
|
async fn main() -> Result<(), Box<dyn Error>> {
|
||||||
let clap_matches = Options::clap().get_matches();
|
let clap_matches = Options::clap().get_matches();
|
||||||
let options = Options::from_clap(&clap_matches);
|
let options = Options::from_clap(&clap_matches);
|
||||||
|
|
||||||
@ -53,6 +54,9 @@ fn main() -> Result<(), Box<dyn Error>> {
|
|||||||
#[cfg(debug_assertions)]
|
#[cfg(debug_assertions)]
|
||||||
println!("{:?}", options);
|
println!("{:?}", options);
|
||||||
|
|
||||||
|
#[cfg(feature = "sqlite")]
|
||||||
|
let sqlite_connection = connect_sqlite(&config.database_path).await?;
|
||||||
|
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user