In my last blog post, I mentioned that GitHub for Windows (GHfW) works with non-GitHub repositories, but I didn’t go into details on how to do that. GHfW is optimized for GitHub.com of course, but using it with non-GitHub repositories is quite easy.
One key difference is that you need to clone the repository to your local machine first following the instructions for your respective host. If your host offers an HTTPS git repository URL, use that one.
For example, suppose you want to work on a project hosted on CodePlex.com. In my case, I’ll choose NuGet. The first thing you need to figure out is how to clone it locally. In CodePlex, click on the Source Code tab and then click on the sidebar Git link to get the remote URL. If there is no Git link, then you are out of luck.
Next, use the Git Shell that GHfW installs to clone the repository to your machine with the following command.
git clone https://git01.codeplex.com/nuget
Pay attention to where you clone the repository so you can find it in Explorer.
Found it!Now drag and drop it into the GitHub for Windows dashboard. Pretty easy!
You’ll see the repository listed in the list of local repositories. Double click the repository (or click on the blue arrow) to navigate to the repository.
The first time you navigate to the repository, GHfW prompts you for your credentials to the Git host, in this case, CodePlex.com. This probably goes without saying, but do not enter your GitHub.com credentials here.
GHfW will securely store the credentials for this repository so that you only need to enter it once. GHfW acts as a credentials provider for Git so the credentials you enter here will also work with the command line as long as you launch it from the Git Shell shortcut that GHfW installs. That means you won’t have to enter the credentials every time you push or pull commits from the server.
With that, you’re all set. Work on your project, make local commits, and when you’re ready to push your changes to the server, click on the sync button.
While we think you’ll have the best experience on GitHub.com, we also think GitHub for Windows is a great client for any Git host.