From 396baee9916e9cf42577549a5e8ce2782fb06604 Mon Sep 17 00:00:00 2001 From: Aditya Date: Tue, 23 Jun 2026 14:32:22 +0530 Subject: [PATCH] fix: hide tauri window-state.json from the note list --- src-tauri/src/commands/fs.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src-tauri/src/commands/fs.rs b/src-tauri/src/commands/fs.rs index 0db0d35..1665e06 100644 --- a/src-tauri/src/commands/fs.rs +++ b/src-tauri/src/commands/fs.rs @@ -54,6 +54,10 @@ fn walk_dir(dir: &Path, notes: &mut Vec, base_path: &Path) -> Result<(), S if path.is_dir() { walk_dir(&path, notes, base_path)?; } else if path.is_file() { + let file_name = path.file_name().and_then(|n| n.to_str()).unwrap_or(""); + if file_name == "window-state.json" || file_name == ".window-state" { + continue; + } let ext = path.extension().and_then(|e| e.to_str()).unwrap_or(""); if ext == "md" || ext == "json" { let content = fs::read_to_string(&path)