Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Add index tracking to status
Mikayla Maki1e4ab6cd75f8
diff --git a/crates/fs/src/repository.rs b/crates/fs/src/repository.rsindex 51b69b8bc7a..4163dbab900 100644--- a/crates/fs/src/repository.rs+++ b/crates/fs/src/repository.rs@@ -100,9 +100,9 @@ impl GitRepository for LibGitRepository {fn read_status(status: git2::Status) -> Option<GitFileStatus> {if status.contains(git2::Status::CONFLICTED) {Some(GitFileStatus::Conflict)- } else if status.intersects(git2::Status::WT_MODIFIED | git2::Status::WT_RENAMED) {+ } else if status.intersects(git2::Status::WT_MODIFIED | git2::Status::WT_RENAMED | git2::Status::INDEX_MODIFIED | git2::Status::INDEX_RENAMED) {Some(GitFileStatus::Modified)- } else if status.intersects(git2::Status::WT_NEW) {+ } else if status.intersects(git2::Status::WT_NEW | git2::Status::INDEX_NEW) {Some(GitFileStatus::Added)} else {None