At the top of my head, I would say that git2.dll(the compiled version of the C library libgit2 ) is not in your output directory ( bin\[Release|Debug]).
Since git2.dllit is not a managed dependency, you cannot reference it from your project.
However, thanks to the pre-build event, you should be able to copy the binary to the output directory.
Another option would be to link to the DLL file from your solution and change its properties to make it "copied if newer" (see below)

If you encounter any problems, create a problem in tracking errors .
It will be easier to track; -)
UPDATE:
, , libgit2.dll , LibGit2Sharp.dll. , , .
git2.dll ( C libgit2 (bin\[Release|Debug]).