gitui/asyncgit
Johannes Agricola a91132d187
Bump git2 from 0.20.0 to 0.20.1 (#2567)
* Bump git2 from 0.20.0 to 0.20.1

Bumps [git2](https://github.com/rust-lang/git2-rs) from 0.20.0 to 0.20.1.
- [Changelog](https://github.com/rust-lang/git2-rs/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/git2-rs/compare/git2-0.20.0...git2-0.20.1)

---
updated-dependencies:
- dependency-name: git2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Avoid passing reference into struct

git2-rs changed the lifetime of the result of Patch::hunk() to reference
the patch struct:
https://github.com/rust-lang/git2-rs/pull/1141

Thus, returning a patch struct and a reference into it is flagged by the
borrow checker upon move when returning.

This patch avoids returning both alltogether by separating retrieving
and retrieving the patch.

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Naseschwarz <naseschwarz@0x53a.de>
2025-03-18 09:09:11 +01:00
..
src Bump git2 from 0.20.0 to 0.20.1 (#2567) 2025-03-18 09:09:11 +01:00
Cargo.toml Change links to point to gitui-org instead of extrawurst (#2538) 2025-03-16 15:33:28 +01:00
LICENSE.md chore: Add LICENSE file into the sub-crates 2020-05-28 16:11:54 +02:00
README.md little more documentation 2020-07-08 00:00:17 +02:00

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.