explore replacing plugins/git
nom
parser with libgit2
function calls
#575
Labels
plugins/git
nom
parser with libgit2
function calls
#575
To get commit diffs for a repo, our
git
plugin currently uses a configuredgit log
message to get the entire diff history the repo, and uses anom
parser to extract data intoDiff
objects. The log data we parse does not include commit hashes, so if there are any corner cases, the parser will fail andcommits.len() != diffs.len()
. Rather than relying on the parser, we should see if we can use the Rustlibgit2
bindings to synthesizeCommitDiff
objects in a much more reliable way.This link shows example code in C of how to use the libgit2 API to get
git log
-like info. The task will be to see if we can do something similar to get the diff info we need to constructCommitDiff
objects, and preferably remove the need tozip
two independently-derivedVec
s together.The text was updated successfully, but these errors were encountered: