libgit2sharp
libgit2sharp copied to clipboard
Custom refdb backend support
This is a rewrite of zoxiv's refdb backend PR #1482 (their code here), since that targeted an ancient libgit2 with substantial API changes since then.
Changes due to libgit2:
- Iterators had to be completely reworked, since
foreachandforeach_globwere replaced with a newiteratorcallback in libgit2. Replaced them with a method that returnsIEnumerable<ReferenceData>. - libgit2 now "requires" reflog support for backends. I've created stubs for these callbacks, since those APIs are cumbersome, they're not called unless reflog tracking is opted into, and most use cases for custom RefDbs don't require reflog support.
Other changes:
- Added rename support.
- Used
RefdbBackendExceptionsto signal errors, which simplifies the glue and lets native libgit2 error codes be returned.
It looks like AppVeyor failed with some build machine issue:
git clone -q https://github.com/libgit2/libgit2sharp.git C:\projects\libgit2sharp
fatal: unable to access 'https://github.com/libgit2/libgit2sharp.git/': Failed to connect to github.com port 443: Timed out
Command exited with code 128
Could a maintainer please rerun the check?
is there any hope this pr will be merged?
@bording Is it possible for you to look at this? We utilitize the features this PR adds as well and have to maintain our own fork.