rename subfolder

This commit is contained in:
2023-06-28 14:06:28 +02:00
parent 509412599f
commit 0fbdcc084e
11 changed files with 15 additions and 8 deletions

View File

@ -1,5 +1,7 @@
pub mod model;
pub mod rest;
#[cfg(feature = "rowing-tera")]
pub mod tera;
#[cfg(test)]
#[macro_export]

View File

@ -1,16 +1,17 @@
use std::str::FromStr;
use rot::rest;
#[cfg(feature = "rowing-tera")]
use rot::tera;
use sqlx::{pool::PoolOptions, sqlite::SqliteConnectOptions, ConnectOptions};
#[macro_use]
extern crate rocket;
#[cfg(feature = "rowing-tera")]
#[launch]
async fn rocket() -> _ {
env_logger::init();
//let pool = SqlitePool::connect(":memory:").await.unwrap();
let mut connection_options = SqliteConnectOptions::from_str("sqlite://db.sqlite").unwrap();
connection_options.log_statements(log::LevelFilter::Debug);
let pool = PoolOptions::new()
@ -18,5 +19,5 @@ async fn rocket() -> _ {
.await
.unwrap();
rest::start(pool)
tera::start(pool)
}

View File

@ -1,7 +1,7 @@
use rocket::{get, routes, Route, State};
use sqlx::SqlitePool;
use crate::{model::log::Log, rest::Config};
use crate::{model::log::Log, tera::Config};
pub mod planned_event;
pub mod user;