diff --git a/src/config.rs b/src/config.rs index 11a32ac..deafcea 100644 --- a/src/config.rs +++ b/src/config.rs @@ -62,7 +62,7 @@ pub fn global_config() -> Config { } impl YoutubeConfig { - const DEFAULT_POSTPROCESSOR_ARGS: &'static str = "ffmpeg:-vf setsar=1 -c:v libx264 -crf 20 -preset ultrafast -c:a aac -b:a 128k -movflags +faststart"; + const DEFAULT_POSTPROCESSOR_ARGS: &'static str = "ffmpeg:-vf setsar=1 -c:v libx264 -crf 20 -preset veryfast -c:a aac -b:a 128k -movflags +faststart"; fn from_env() -> Self { Self { diff --git a/src/main.rs b/src/main.rs index 2b69d56..5a6ed77 100644 --- a/src/main.rs +++ b/src/main.rs @@ -2,6 +2,7 @@ use dotenv::dotenv; use teloxide::{prelude::*, respond}; use tg_relay_rs::{ comments::Comments, + config::Config, handler::{Handler, create_handlers}, telemetry::setup_logger, }; @@ -23,6 +24,10 @@ async fn main() -> color_eyre::Result<()> { .init() .expect("failed to initialize comments"); + Config::from_env() + .init() + .expect("failed to initialize comments"); + let bot = Bot::from_env(); info!("bot starting");