Cloning a GitHub project into Visual Studio 2013 - github

The canonical question on 'how to use Git in Visual Studio?' appears to be this one posted by Herb Caudill.
One of the more recent answers notes (correctly) that "Visual Studio 2013 natively supports Git".
So when I go to a Github page (supercolider's is the one I'm trying to clone) and click on the 'Clone in Desktop' button I would expect (hope) that Visual Studio 2013 would take up the link and clone the repository. That is not what happens, instead Windows (I'm using 8.1) asks me if I would like to visit the store to find an app that can handle files of type (github-windows).
What is the correct way to clone a GitHub repository in Windows under Visual Studio 2013? The various MSDN pages (e.g. Share your code in Git or Setup Git on your dev machine) mention GitHub but do not explain how to use it.

It is super easy once you know how :)
From within Visual Studio 2013:
Select File -> Open -> Open From Source Control
The Team Explorer window will come up, one of the sections is "Local GIT repositories". In that section choose "Clone".
That will bring up a path selection textbox and directory browser. Simply replace the default path with the git URL (in your case "https://github.com/supercollider/supercollider")
Thats it!
Note: unless specified otherwise, Visual Studio will store the actual files here:
C:\Users\\Source\Repos\

What you do is go to the Team Explorer, click the Connect to Team Projects, select the Clone option and enter the URL of the Repo you wish to clone and press Clone

To expand on neo12's answer & address the canonical question "how to use Git in Visual Studio"
I agree with neo12. Additionally you can also navigate directly to solutions from the Team Explorer "Local Git Repositories" section by double clicking them
Here is a walk through I put together to explain in concise detail. The video is less than 2 minutes. Let me know if this helps.
http://prestoasp.net/lesson/how-to-work-with-visual-studio-github/

Related

How do I get the Git menu to appear in Visual Studio 2019?

Visual Studio is connected to GitHub in Manage Connections > GitHub
I have GitHub Extensions for Visual Studio installed.
In Preview Features, the following are checked...
GitHub Action support in Publish
New Git user experience
I am running Visual Studio in Admin mode.
I have restarted the compute and Visual Studio multiple times.
I have a local repo opened.
I have been able to connect the project to GitHub and commit code already, but now I am unable to.
I can see the menu in the Extensions > Customize Menu dialog (see attached).
Still, my repo is not connected to GitHub and I don't see the menu item.
What am I doing wrong?
Can you see "Add to Source Control" in lower right corner of Visual Studio window? If yes, click it and then click Git. In my case, Git menu appeared after this action.
In my case there was no "Add to Source Control" in lower right corner. File > Clone repository... also did not help. But I was able to connect to remote repository via VS Get Started window.

How to open your own github repo from github.dev

In the new product of Microsoft, github.dev, you are automatically forwarded to a VSCode web IDE. However, I am not sure if it is possible to open your own repo (hosted on github.com), work on it and push the changes. Can you help explain if this can be done and how?
I do not seem to find a straightforward tutorial on that.
Note that I was able to open a repo of mine by clicking on the blue GitHub icon in the bottom left corner, but I fail to install a terminal, because
Terminals are not available for web editor. To use terminal you need to continue working in an environment that can run code, like codespaces or local VS Code
I read that codespaces are a paid option for github enterprise, but the way this error message is written might suggest other ways.
Opening your repository
You can open your repository by visiting it's page on GitHub and pressing . to open it in github.dev. You can also use the url format https://github.dev/<username>/<repo-name> with the path to your repository.
Making Commits
While the terminal cannot be used in the editor, you can make commits using the VSCode source control system.

How do I commit to a remote repository on Visual Studio?

I figure this may be somewhat of a common question, but I am still having trouble with what I am finding. Note: I am very new to deploying applications. I have created my first application, an ASP.NET MVC application using Visual Studio Community 2015(I am using enitity framework for the database if that matters). It is time for me to deploy it. I have all my files on gitHub. Now I believe it is time for me to commit to my remote repository on AppHarbor (which I have the link for), but I just can't seem where to do it. It seems to be so simple. I'm using the team explorer. Again, I am very new to programming and deploying applications, so any help would be amazing. Again, from what I understand I need to connect to my remote repository now. I could be wrong. Thank you very much for any insight.
Inside Visual Studio, open the 'Team Explorer - Connect' Window. Default Shortcut for that should be Ctrl+/ + Ctrl+M.
Inside the Team Explorer window, Click on the green plug like button that you see that says "Manage Connections". You will be able to connect to your remote repo from here.
After that, Click on 'Clone' and paste your repo's URL in the yellow text box:
If your remote repo is on the GitHub, this is where you can find the URL to your remote repo:
Well, that's it.. you're connected! To commit your changes, you can easily find the "Changes" section in 'Team Explorer' window. Here's a screenshot for that too:
Note that in my case some of the buttons shown may be Disabled. That should not be a problem to you if you have files with changes, etc.
I don't know about Visual Studio, but with git you need to push your changes to a remote repo, so maybe you have a "push" somewhere ?
First you need to add this remote repository.

Remove Git binding from Visual Studio 2013 solution?

I was adding a new Solution to TFS in Visual Studio 2013, and I selected Git as opposed to TFS.
I want to remove the Git binding, and add TFS.
I know you can remove TFS binding from File -> Source Control, but this doesn't seem to be an option here.
How can I remove Git binding from a Visual Studio solution, and add TFS?
Thanks
I don't believe Visual Studio adds anything special for git integration. It just looks for the presence of the .git directory in the solution folder. Delete that folder, possibly hidden, and Visual Studio will no longer consider it a git project.
As #JaredPar mentioned, if you delete the highlighted directories and reload the solution then the solution would no longer be under source control.
Go to Quick Launch(Ctrl+Q)
Search for "Source"
Select the following option
Select the Dropdown list
Choose your source control from list and click "ok"
Just as a side note. If you by accident create a Git repository in a parent folder of a project under TFS, Visual Studio will use Git as source control for that project too.

Git Extensions vs GitHub for Windows

I am using Visual Studio 2010 Express. I know that this edition does not support git extensions integration. So I have tried a standalone source control Gui like git extensions but today I have seen another possibility that is GitHub for Windows.
I would like to know which is the difference between Git extensions and GitHub for Windows.
As illustrated here, GitHub for Windows (G4W) can interface with only the latest version of Visual Studio.
This is the main difference, in the context of your question, with Git Extensions, which is a plugin for Visual Studio (2005/2008/2010/2012), as shown in this article.
As such, Git Extensions isn't a "stand alone GUI".
You would compare, for "stand alone" GUIs, a G4W and an Atlassian Stash for instance.
I ran into the same question. Maybe this will help the next person.
Git for Windows - is a lightweight, native set of tools that bring the full feature set of the Git SCM(source control management software) to Windows while providing appropriate user interfaces for experienced Git users and novices alike. (source)
This tool can also be installed separately by visiting https://git-for-windows.github.io. This tools is not just for github but for git in general.
GitHub Extensions for Visual Studio - "lets you connect to GitHhub.com or GitHub enterprise and work with GitHub repositories inside of the visual studio IDE." (source: MS help) It adds a functionality(like context menus) inside of Visual Studio for things like creating and cloning repositories. (more here)
Git for windows lack lot of must have feature. gitextensions is most powerful GUI I ever use. Go for https://code.google.com/p/gitextensions/