Azure Repos on Git for Projects- Guidelines to create and clone

Azure Repos on Git for Projects- Guidelines to create and clone

"A repo is a container/ version control tool which is used to store and manage historical changes on the code in a systematic way"

No alt text provided for this image
Benefits of Azure Repos on Git

For more detailed comparison between Git and TFVC refer the below link:

Let's look how Azure Repos is being used on Projects in Azure DevOps.

  1. Create New Project -> Enter Project Name -> Advanced -> Select Version Control as Git -> Select Process as Agile -> Create

No alt text provided for this image

2. Open Project -> Azure Repos -> File -> Copy the clone URL

No alt text provided for this image

To clone the repository to local machine, Git should be installed in the local machine. Below video provides the complete guidelines to download, install and configure Git in local system.

Let's look how repo is being cloned to local system. I'll be following command prompt method for the process.

  1. Open Repos -> Copy HTTPS URL

No alt text provided for this image

2. In local machine -> Open a folder -> Enter "cmd" in folder path to Open command prompt from that folder

No alt text provided for this image

3. In cmd, enter "git clone <paste clone URL>" -> press enter

No alt text provided for this image

4. Git Credential Manager opens to authenticate to the Azure Project. Enter login credentials to signin.

No alt text provided for this image

5. Once signed in, empty repository will be cloned to local machine. Repo name will be similar to the Azure repo name in the project

No alt text provided for this image

Cloning repository via Visual Studio or any IDE is possible. Below video gives the guideline for cloning from IDE.

6. Add the files in the cloned repository. Open cmd from the cloned repository.

No alt text provided for this image


7. In cmd, enter command "git add --all" to copy the files from local repository to server repository. -> press enter

No alt text provided for this image

8. Now commit the files to server from local repo with a message using command "git commit -m "test repo import" -> press enter

No alt text provided for this image

9. Synchronize local files to server using command "git push" -> press enter

No alt text provided for this image

10. On Azure Repos, refresh the web page to view the files being pushed to server from local.

No alt text provided for this image

11. Commit details can be viewed in Repos -> Commits

No alt text provided for this image

12. Push details can be viewed in Repos -> Pushes

No alt text provided for this image

Hope this article has provided a brief insight on Azure Repos and its usage.

Thank You!




To view or add a comment, sign in

More articles by Aruliny Thiruchelvan

Others also viewed

Explore content categories