diff options
| author | WriterV2 <primary-v2@protonmail.com> | 2024-11-05 16:33:19 +0100 |
|---|---|---|
| committer | WriterV2 <primary-v2@protonmail.com> | 2024-11-05 16:33:19 +0100 |
| commit | dab09c4e4d1e4b21216b630bb44e57f597dfe85b (patch) | |
| tree | 5c01c51c49ba4b64b03ffe9ca65c1d0ac5cd1eef /src/main.rs | |
| parent | 56233352feb78ec6da39d8ab7734102abae1e4ed (diff) | |
Feat: auto file (pdf + epub) creation and synchronization for story
Diffstat (limited to 'src/main.rs')
| -rw-r--r-- | src/main.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main.rs b/src/main.rs index ffdce27..dfe1447 100644 --- a/src/main.rs +++ b/src/main.rs @@ -3,6 +3,8 @@ use std::env; use dotenvy::dotenv; use sqlx::sqlite::SqlitePoolOptions; +use self::db::story; + pub mod db; mod error; mod handlers; @@ -23,6 +25,10 @@ async fn main() { .await .expect("Failed to run migrations"); + story::synchronize_story_files(&pool) + .await + .expect("Failed to synchronize files"); + let listener = tokio::net::TcpListener::bind("0.0.0.0:3000").await.unwrap(); axum::serve(listener, handlers::router(pool).await.into_make_service()) .await |
