libgit2sharp icon indicating copy to clipboard operation
libgit2sharp copied to clipboard

using SSH instead of username\password

Open shersh opened this issue 3 years ago • 7 comments

Because of username and password deprication https://github.blog/2020-12-15-token-authentication-requirements-for-git-operations/

We should use SSH keys for auth. How I can to do it with lib?

shersh avatar Apr 23 '21 10:04 shersh

You may find the link interesting: clone a git repository with SSH and libgit2sharp

and this thread https://github.com/libgit2/libgit2sharp/issues/1422

aloisdg avatar Jul 07 '21 10:07 aloisdg

@aloisdg Thx, but it 5 years old and no commit this time, so it is not working solution

shersh avatar Jul 07 '21 11:07 shersh

@shersh I plan to do it quite barebone with a powershell call to git

aloisdg avatar Jul 07 '21 13:07 aloisdg

Hello, I trying to use LibGit2Sharp with SSL.

I merged libgit2sharp master branch with SSL branch. Thats ok!

But, how to get git2 dll and libssh/zlib updated DLLs for Windows ? I'm trying to build libgit2 but it seems to be a quite complex...

digao-dalpiaz avatar Feb 23 '22 01:02 digao-dalpiaz

@digao-dalpiaz digao-dalpiaz

You can build git2.dll. Just go thru the "Quick Start" section. You need VS and python(if you require tests) installed. After that install cmake.

  1. clone the repo
  2. go to the cloned folder(cd )
  3. mkdir build
  4. cd build
  5. cmake ..

Build

The above will create the necessary things under the build folder. You can open the .sln file using VS. And build in VS.

OR

cmake --build .

The above step will create the .dll file under the bin folder.

naushadckk avatar Mar 23 '22 08:03 naushadckk

Hello, is there still no ssh support in libgit2sharp? I found a repo with an ssh extension to libgit2sharp but the last commit is from 2016... so we won't be using this I guess.

ssh would be a great addition to this tool

hbertsch avatar Jul 27 '23 06:07 hbertsch

This is such a bummer. I was really excited about this library before I found out about this lack of SSH support. I understand the explanation provided in #1422 but I don't get why it can't be a use-at-your-own-risk kind of option.

adwitkow avatar Feb 04 '24 11:02 adwitkow