Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

MS Visual Studio + gitolite or github via ssh

I have MSVS 2013 + git 1.8.4 + git-extensions 2.47.3 on local machine and gitolite 2.3-1 on remote server

I could clone commit and push my project ([email protected]:testproject) by console tools and via git-extension GUI

But I couldn't do the same from "Team Explorer" in MSVS. Even if I clone it manually (by console tool) and add as local repository to MSVS Team Explorer, I can't commit or push, because

An error occurred. Detailed message: An error was raised by libgit2. Category = Net (Error). This transport isn't implemented. Sorry

Everything I found related is about TFS or local git integration.

Same with github project.

Is it even possible to make it work? By some console hooks or something like that?

like image 921
brammator Avatar asked Dec 29 '13 17:12

brammator


People also ask

How do I clone a Git repository in Visual Studio using SSH?

Visit your repository on the web and select the Clone button in the upper right. Select SSH and copy the new SSH URL. In your Git client, run: git remote set-url <remote name, e.g. origin> <new SSH URL> . Alternatively, in Visual Studio, go to Repository Settings, and edit your remotes.

Can I use SSH Git authentication with VS code?

VS Code works most easily with SSH keys without a passphrase. To use SSH Git authentication with VS Code, you have launch VS Code from a Git Bash prompt to inherit its SSH environment.

What is Visual Studio with GitHub?

With Visual Studio Publish you can setup GitHub Actions for ASP.NET Core applications being deployed to Azure with ease. Visual Studio will generate a working GitHub Actions workflow for you with just a few clicks.

How do I use GitHub code in Visual Studio?

Clone a GitHub repo and then open a project Open Visual Studio 2019 version 16.7 or earlier. On the start window, select Clone or check out code. Enter or type the repository location, and then select Clone. Visual Studio opens the project from the repo.


1 Answers

The "Team Explorer" uses the Git integration added with Visual Studio 2013.
See "Clone a remote Git repository from a third-party service".

With that Git native integration in Visual Studio, only https is supported.
Ssh isn't yet supported.

http://i.msdn.microsoft.com/dynimg/IC698706.png

This MSDN blog post stated in October 2013:

As of this writing, Visual Studio 2013 does not have support for ssh-based remotes.
If you have a Git remote that uses SSH and you try to perform a network operation in Visual Studio, you’ll get the message “This transport isn’t implemented. Sorry.” (This message comes from the libgit2 library.)
I don’t have a timeline for when support for SSH remotes might be implemented in Visual Studio.


Update Oct. 2015:

However, as Vladimir Koltunov mentions below, libgit2 is starting (Q4 2015) to be built (for VS 2015) with ssh support in project PROGrand/git2-msvstfs-ssh-patch.

This patch for 'libgit2' allows usage of SSH public/private keys pair with ssh repositories (such as gitolite) in Visual Studio 2015

like image 106
VonC Avatar answered Sep 23 '22 03:09

VonC