From dfeb67f93cb96c40952caaf423d2b8ccfbbce3f1 Mon Sep 17 00:00:00 2001 From: David Kleingeld Date: Fri, 7 Nov 2025 13:31:43 +0100 Subject: [PATCH] enjoy Co-authored-by: Jakub Konka --- Cargo.toml | 2 +- crates/git_ui/src/project_diff.rs | 6 +++++- crates/language/src/buffer.rs | 1 + crates/project/src/git_store/branch_diff.rs | 2 ++ 4 files changed, 9 insertions(+), 2 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index ac6e310fe7d899486c5b5287f4ac07762751d9a1..463785b3970fb134ddd6698a037d109a1d577a8b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -839,7 +839,7 @@ ui_input = { codegen-units = 1 } zed_actions = { codegen-units = 1 } [profile.release] -debug = "limited" +debug = "full" lto = "thin" codegen-units = 1 diff --git a/crates/git_ui/src/project_diff.rs b/crates/git_ui/src/project_diff.rs index b5906e75853a2ce4f691617013584ce20c26c83c..41d625205f549dadd36131c82acfcd56dec35af0 100644 --- a/crates/git_ui/src/project_diff.rs +++ b/crates/git_ui/src/project_diff.rs @@ -32,7 +32,7 @@ use project::{ }, }; use settings::{Settings, SettingsStore}; -use std::any::{Any, TypeId}; +use std::{any::{Any, TypeId}, time::Duration}; use std::ops::Range; use std::sync::Arc; use theme::ActiveTheme; @@ -590,6 +590,10 @@ impl ProjectDiff { .ok(); })?; } + cx.background_executor().timer(Duration::from_millis(5)).await; + this.update(cx, |_, cx| { + cx.notify(); + })?; } this.update(cx, |this, cx| { this.pending_scroll.take(); diff --git a/crates/language/src/buffer.rs b/crates/language/src/buffer.rs index 69e6b0a553cdb8c7ec90f1f19099f7cbc2a03e97..63a86c45230271c4e92650611d9ed4e5a48101cb 100644 --- a/crates/language/src/buffer.rs +++ b/crates/language/src/buffer.rs @@ -969,6 +969,7 @@ impl Buffer { /// Builds a [`Buffer`] with the given underlying [`TextBuffer`], diff base, [`File`] and [`Capability`]. pub fn build(buffer: TextBuffer, file: Option>, capability: Capability) -> Self { + log::info!("file: {:?}", file.as_ref().map(|f| f.path())); let saved_mtime = file.as_ref().and_then(|file| file.disk_state().mtime()); let snapshot = buffer.snapshot(); let syntax_map = Mutex::new(SyntaxMap::new(&snapshot)); diff --git a/crates/project/src/git_store/branch_diff.rs b/crates/project/src/git_store/branch_diff.rs index 08dbd77a541f01a52dbb9b0d10c5af3a377170f9..44b3b3fb685cfc3c35d2a52cae84506da93a1af6 100644 --- a/crates/project/src/git_store/branch_diff.rs +++ b/crates/project/src/git_store/branch_diff.rs @@ -319,6 +319,8 @@ impl BranchDiff { }); } }); + // let names: Vec<_> = output.iter().map(|o| o.repo_path.as_unix_str()).collect(); + // eprintln!("OUTPUT IS *********************************: {names:?}"); output }