Enhance git module performance and improve path collection

- Conducted a complete audit of the git module to leverage the gix API for improved performance, aiming for significant speedups in git operations.
- Updated the `git_changed_files_impl` function to accept project prefixes as a vector of strings, enhancing the flexibility of change detection.
- Made the `collect_path_roots` function public to allow external access for collecting project directory paths.

These changes aim to optimize git operations and improve the overall efficiency of path handling in the project.
This commit is contained in:
Joe 2026-03-01 17:43:27 -06:00
parent 8d54fff7df
commit 1a03554ee8
4 changed files with 111 additions and 349 deletions

View file

@ -264,7 +264,7 @@ fn prefetch_project_files(project: &Project) -> io::Result<PrefetchCache> {
}
/// Recursively collect all `$path` directories from the project tree.
fn collect_path_roots(node: &crate::project::ProjectNode, base: &Path, out: &mut Vec<PathBuf>) {
pub fn collect_path_roots(node: &crate::project::ProjectNode, base: &Path, out: &mut Vec<PathBuf>) {
if let Some(path_node) = &node.path {
let resolved = base.join(path_node.path());
out.push(resolved);