

Finally, click the Clone button located under.ģ.
#VISUAL STUDIO 2013 GIT CREATE BRANCH CODE#
Choose a folder on your local machine to copy the code to. Under the Local Git Repositories section, click the Clone link and paste the link copied in the previous step. In Visual Studio 2012 or above, open Team Explorer and click on the Connection button: Cloning the repository from Visual Studio: Getting the clone link from the Git repository:Ģ.
#VISUAL STUDIO 2013 GIT CREATE BRANCH HOW TO#
The sample hereunder shows how to clone a Git repository from GitHub but the principle is the same for every Git repositories: 1.

If you have never used Git repositories, you can check previous articles I wrote on the topic and notably where I detail Git support for various versions of Visual Studio: Git TFS Visual Studio Integration. I will here under demonstrate how to get code hosted on a Git repository for the first time (aka clone the repository).

The technical term to get code from a Git repository for the first time is to clone the repository. This is fine but there is actually a better way to grab code from Git repositories through Visual Studio. Nevertheless, I often see people getting code from Git repositories by downloading a zip file, unzipping it and then opening it up in Visual Studio. It is a very convenient way to distribute code samples so that developers can browse the code through Visual Studio and eventually run it and toy with it. There are lots of open source projects hosted on Git repositories as well as bloggers and authors publishing demos, patterns and code samples on web-hosted Git repositories such as GitHub, Bitbucket, Codeplex (Note: Codeplex has several source control options and Git is just one of them)…. Cloning (getting) code from Git repository to Visual Studio.
