mirror of
https://github.com/gitui-org/gitui
synced 2026-05-23 17:08:21 +00:00
* perf: prevent repeated status fetches in large repos Replace time-based cache invalidation with a generation counter. The old `StatusParams` included a millisecond timestamp (tick) in its hash, causing the cache to invalidate on every UI tick. For large repos with millions of files, this led to repeated index loading and 5+ minute load times. This change uses a different strategy to manage cache invalidation: - Remove tick from StatusParams hash - Add generation counter that increments after each fetch completes - Include generation in cache hash This ensures: - No repeated fetches while one is already pending, making gitui usable in large repos - New fetch starts immediately after completion, keeping gitui responsive in small repos - External file changes will still be detected on the next fetch cycle * fix changelog --------- Co-authored-by: Daniel Stoll <dstoll@radix.trade> Co-authored-by: extrawurst <776816+extrawurst@users.noreply.github.com> Co-authored-by: extrawurst <mail@rusticorn.com> |
||
|---|---|---|
| .. | ||
| src | ||
| Cargo.toml | ||
| LICENSE.md | ||
| README.md | ||
asyncgit
allow using git2 in an asynchronous context
This crate is designed as part of the gitui project.
asyncgit provides the primary interface to interact with git repositories. It is split into the main module and a sync part. The latter provides convenience wrapper for typical usage patterns against git repositories.
The primary goal however is to allow putting certain (potentially) long running git2 calls onto a thread pool.crossbeam-channel is then used to wait for a notification confirming the result.
In gitui this allows the main-thread and therefore the ui to stay responsive.