How to Clone a Git Repository into a Specific Folder?

In this tutorial I will show you how to clone an existing Git repository.

Step 1: Open Terminal (for Mac and Linux users) or the command prompt (for Windows users).

Step 2: Change the current working directory to the location where you want the cloned directory to be made.

Step 3: Use git clone command to clone the repository.

git clone folder-name

Press Enter. Your local clone will be created. The screenshot below shows OpenCV repository being cloned.

Git Clone of OpenCV

Other related posts:
Git Delete a Local or Remote Branch
Change the URI for a Remote Git Repository
How to Merge a Local Git Branch with Master
How to Setup Aliases and Shortcuts for Git Commands
How to create a .gitignore file in Windows

This content has been helpful to you?

Thanks for contributing!

Yes No