Smarter detection of git trees in file picker #983
Labels
A-helix-term
Area: Helix term improvements
C-enhancement
Category: Improvements
E-medium
Call for participation: Experience needed to fix: Medium / intermediate
Related: to:
A real world scenario for your consideration: the repository that I work on in my job contains 36,504 files tracked by git (
git ls-files|wc -l
), 564,380 files total (including build artefacts etc.,find . -type f | wc -l
). Because it's so large I use git worktrees to have multiple worktrees but only one copy of the 3.8Gb git repo. The naïve check for.git
done here:helix/helix-term/src/ui/mod.rs
Lines 132 to 137 in 39584cb
does not handle this case as the work trees do not have a
.git
directory, which results in the file list being capped at 8k files. There's also the issue raised on #187 that the check does not work when you are not in the top level of the project.In my vim config I use https://github.com/lotabout/skim.vim this readily handles extremely large file tree (such as accidentally running it in my home directory) and since the UI is responsive while results are streaming it it's easy to hit Esc and cancel it if this was a mistake.
I guess my point to all of this is in an ideal scenario the file limit would be removed (thus removing the need for the
.git
check) and the UI would support cancellation of loading large trees.The text was updated successfully, but these errors were encountered: