add mysql support

This commit is contained in:
Sebastian Hugentobler 2024-05-11 18:51:55 +02:00
parent ac0ac8a10d
commit 966373b8fa
Signed by: shu
GPG Key ID: BB32CF3CA052C2F0
3 changed files with 4 additions and 4 deletions

View File

@ -11,7 +11,7 @@ config = "0.14.0"
futures = "0.3.30"
reqwest = { version = "0.12.4", features = ["json", "rustls-tls"], default-features = false }
rumqttc = "0.24.0"
sea-orm = { workspace = true, features = [ "with-time", "sqlx-sqlite", "sqlx-postgres", "runtime-tokio-rustls", "macros" ] }
sea-orm = { workspace = true, features = [ "with-time", "sqlx-sqlite", "sqlx-postgres", "sqlx-mysql", "runtime-tokio-rustls", "macros" ] }
serde = { workspace = true }
serde_json = "1.0.116"
thiserror = "1.0.59"

View File

@ -4,10 +4,10 @@ use thiserror::Error;
#[derive(Error, Debug)]
#[error("opds error")]
pub enum Error {
/// Error rendering OPDS.
/// Database Error
#[error("opds error")]
DbError(#[from] DbErr),
/// Error fetching data from calibre.
/// Error fetching data from alertswiss
#[error("data error")]
FetchError(#[from] reqwest::Error),
}

View File

@ -12,7 +12,7 @@ async fn main() {
let config = args.into();
if let Err(e) = alert_me::run(config).await {
error!("Application error: {e}");
error!("Application error: {e:?}");
process::exit(1);
}
}