From 2e3fe2d8f37d54a6ac49ad3080619208bb54a7f3 Mon Sep 17 00:00:00 2001 From: "lauren n. liberda" Date: Fri, 3 Nov 2023 22:43:52 +0100 Subject: [PATCH] ignore kate-swp files (#2353) --- components/utils/src/fs.rs | 2 ++ src/cmd/serve.rs | 1 + 2 files changed, 3 insertions(+) diff --git a/components/utils/src/fs.rs b/components/utils/src/fs.rs index f05884f4ef..1d3dbdfa5c 100644 --- a/components/utils/src/fs.rs +++ b/components/utils/src/fs.rs @@ -199,6 +199,8 @@ pub fn is_temp_file(path: &Path) -> bool { match ext { Some(ex) => match ex.to_str().unwrap() { "swp" | "swx" | "tmp" | ".DS_STORE" | ".DS_Store" => true, + // kate + "kate-swp" => true, // jetbrains IDE x if x.ends_with("jb_old___") => true, x if x.ends_with("jb_tmp___") => true, diff --git a/src/cmd/serve.rs b/src/cmd/serve.rs index f76dd637b3..b23ffdcc1c 100644 --- a/src/cmd/serve.rs +++ b/src/cmd/serve.rs @@ -728,6 +728,7 @@ mod tests { Path::new("hello.html.__jb_bak___"), Path::new("hello.html~"), Path::new("#hello.html"), + Path::new(".index.md.kate-swp"), ]; for t in test_cases {