Azure Repos

Azure Repos is a set of unversioned code hosting services that you can use to manage your code. It provides a highly scalable and reliable source control solution that is integrated into Azure DevOps.

Key Features

Getting Started with Git

To start using Git with Azure Repos:

  1. Create a new project in Azure DevOps.
  2. Navigate to the Repos section.
  3. Clone an existing repository or create a new one.
Tip: For new projects, Git is generally recommended over TFVC due to its flexibility and widespread adoption.

Cloning a Repository

To clone a repository to your local machine, you can use the Git command-line interface:

git clone <repository_url>

Replace <repository_url> with the URL provided in the Azure Repos interface.

Working with Pull Requests

Pull requests are central to collaborative development in Azure Repos. They allow team members to review code before it's merged into a main branch.

Creating a Pull Request

  1. Make your changes and commit them to a feature branch.
  2. Navigate to the Repos section in Azure DevOps.
  3. Click on "Pull Requests" and then "New pull request".
  4. Select your source branch and the target branch (e.g., main or master).
  5. Add reviewers, a description, and any associated work items.
  6. Click "Create".
Pro Tip: Configure branch policies in your repository settings to enforce mandatory reviewers and successful builds before merging.

Branch Policies

Branch policies help maintain code quality and stability. Common policies include:

Further Reading