Clone A Remote Git Repository

Clone A Remote Git Repository

I need to clone my brand new aspnet-core-webapi-baseline repository to my local computer so that I can start adding new code to it. From here I will periodically push my changes back to my remote repository on GitHub. The reason I created the GitHub repository first is that I personally have found it is easier to check-in code from Visual Studio 2105 into an existing remote repository. Although you can use the Git command line client to do this, I wanted to try out the GitKraken GUI application.

First I downloaded GitKraken, installed it, and logged it into my GitHub repository.

Then I launched GitKraken and I navigated to the Clone a Repo view.

clone-asp-net-core-webapi-baseline-repository

At the top of the right pane, I selected GitHub as the location of my remote repository.

In the Where to clone to input field, I entered C:\srcGit\ to use for the root folder of the new repository on my local computer.

I selected my new aspnet-core-webapi-baseline repository from the Search Remotes list.

In the Full path input field, GitKraken automatically appended my new repository name as a subfolder to the path in which it will create and place the cloned repository.

I clicked the Create the repo! button.

GitKraken indicated that it created my new aspnet-core-webapi-baseline repository.

cloned-asp-net-core-webapi-baseline-repository

I clicked the Open Now button next to the success message.

GitKraken opened the new local copy of my aspnet-core-webapi-baseline repository.

opened-asp-net-core-webapi-baseline-repository

I noticed that GitKraken had already committed the new files to the local Git repository.

I wanted to update the .gitignore file and copy the .gitattributes and global.json files from my standard master copies I previously created and stored in my BasicAspNetCoreSolutionStructure GitHub repository at the following location:

https://github.com/dennismoon/BasicAspNetCoreSolutionStructure

Now I already have this repository on my local computer, so I copied these files from there into the root folder of my new local aspnet-core-webapi-baseline repository.

The files then appeared in GitKraken.

copied-standard-git-files-to-repository

I staged the files and committed them to my local repository.

staged-standard-files-for-commit

I then pushed the commits to my local repository.

push-to-remote-repository

I then selected the newly committed files and pushed them to my remote GitHub repository.

I went out to my aspnet-core-webapi-baseline repository on GitHub where I could see the new and updated files.

added-standard-files-to-asp-net-core-repository

I now have a local copy of my aspnet-core-webapi-baseline repository configured as desired to support adding my pending ASP.NET Core web service code (to be started in my next post).

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s