From c5fb22694e95f12c24b8d8af76999be7aea3fcec Mon Sep 17 00:00:00 2001 From: 魏曹先生 <1992414357@qq.com> Date: Mon, 12 Jan 2026 04:28:28 +0800 Subject: Reorganize crate structure and move documentation files --- crates/vcs_data/src/data/user.rs | 28 ---------------------------- 1 file changed, 28 deletions(-) delete mode 100644 crates/vcs_data/src/data/user.rs (limited to 'crates/vcs_data/src/data/user.rs') diff --git a/crates/vcs_data/src/data/user.rs b/crates/vcs_data/src/data/user.rs deleted file mode 100644 index 9f52fdc..0000000 --- a/crates/vcs_data/src/data/user.rs +++ /dev/null @@ -1,28 +0,0 @@ -use crate::current::current_cfg_dir; -use std::path::PathBuf; - -pub mod accounts; - -pub struct UserDirectory { - local_path: PathBuf, -} - -impl UserDirectory { - /// Create a user ditectory struct from the current system's document directory - pub fn current_cfg_dir() -> Option { - Some(UserDirectory { - local_path: current_cfg_dir()?, - }) - } - - /// Create a user directory struct from a specified directory path - /// Returns None if the directory does not exist - pub fn from_path>(path: P) -> Option { - let local_path = path.into(); - if local_path.exists() { - Some(UserDirectory { local_path }) - } else { - None - } - } -} -- cgit