From a8c50ca481a153a51467acf7cc4e418c952e909b Mon Sep 17 00:00:00 2001 From: Benedikt Peetz Date: Sat, 24 Aug 2024 16:39:26 +0200 Subject: refactor(comments): Remove dead code --- src/comments/mod.rs | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/src/comments/mod.rs b/src/comments/mod.rs index eba391e..aa4cc06 100644 --- a/src/comments/mod.rs +++ b/src/comments/mod.rs @@ -9,11 +9,8 @@ // If not, see . use std::{ - env, - fs::{self}, io::Write, mem, - path::PathBuf, process::{Command, Stdio}, }; @@ -33,22 +30,6 @@ use crate::{ mod comment; mod display; -fn get_runtime_path(component: &'static str) -> anyhow::Result { - let out: PathBuf = format!( - "{}/{}", - env::var("XDG_RUNTIME_DIR").expect("This should always exist"), - component - ) - .into(); - fs::create_dir_all(out.parent().expect("Parent should exist"))?; - Ok(out) -} - -const STATUS_PATH: &str = "ytcc/running"; -pub fn status_path() -> anyhow::Result { - get_runtime_path(STATUS_PATH) -} - pub async fn get_comments(app: &App) -> Result { let currently_playing_video: Video = if let Some(video) = get_currently_playing_video(&app).await? { -- cgit 1.4.1