501 questions
2 votes
0 answers
52 views
How to use an SSH key with a passphrase for credentials in LibGit2Sharp v0.31.0?
I am using the LibGit2Sharp v0.31.0 release and trying to perform Git operations (like clone or fetch) over the SSH protocol. According to the release information, SSH is now supported through libgit2'...
0 votes
0 answers
148 views
How to bypass LibGit2Sharp CertificateCheck (or make SSL work)?
I'm trying to clone a repository using a .NET console app. The git server is behind a kubernetes ingress. When trying to clone it using cmdline, it is working fine. However, when I try to clone the ...
0 votes
0 answers
20 views
Not able to get the OnPushError handler triggered with libgit2sharp
We are using the libgit2sharp library to run git commands on a repository and when there is a remote failure on pushing the git commit, the OnPushError handler doesn't get triggered. using (var repo =...
0 votes
1 answer
94 views
Skip rebase step on conflict with Libgit2sharp
I am performing a rebase operation with libgit2sharp and it works all nice, but I and would like to skip a rebase step when a conflict occurs (if the commit has a specific message) rebaseResult = ...
0 votes
1 answer
120 views
create "master" first branch without commit using libgit2
On shell I can do something below using bash git mkdir -p /tmp/REPO/ROOT && pushd /tmp/REPO/ROOT && git init && git checkout -b anyName As summary above init a local git repo ...
0 votes
1 answer
220 views
Fetch single commit with LibGit2[Sharp]
How can I do the equivalent of git fetch origin <CommitHash> with LibGit2Sharp? It seems the only relevant option for git_remote_fetch are the refspecs so I imagine I need some trickery there, ...
-2 votes
1 answer
197 views
Read a line from a file on a specific commit in C#
I am trying to capture a specific line in a file given a FilePath, LineNumber, and the CommitID (Hash) for that file repo I have stored locally. I have it working except for I have not been able to ...
1 vote
0 answers
128 views
How do I create an in-memory blob with libgit2sharp?
I would like to make a diff between two strings with libgit2sharp. The strings hold file contents loaded elsewhere. The diff.Compare-methods only take blobs, and the constructors of the Blobclass are ...