Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
macos: Use ~/Library/Caches/Zed instead of ~/.cache/zed (#17949)
Peter Tripp7246a0f39ce1
diff --git a/crates/paths/src/paths.rs b/crates/paths/src/paths.rsindex b80bef5f2d6..7f662d0325d 100644--- a/crates/paths/src/paths.rs+++ b/crates/paths/src/paths.rs@@ -59,6 +59,12 @@ pub fn support_dir() -> &'static PathBuf {pub fn temp_dir() -> &'static PathBuf {static TEMP_DIR: OnceLock<PathBuf> = OnceLock::new();TEMP_DIR.get_or_init(|| {+ if cfg!(target_os = "macos") {+ return dirs::cache_dir()+ .expect("failed to determine cachesDirectory directory")+ .join("Zed");+ }+if cfg!(target_os = "windows") {return dirs::cache_dir().expect("failed to determine LocalAppData directory")