Set the Prune remote branches during fetch option to True.Select Tools > Options > Source Control > Git Global Settings.To configure Visual Studio to prune stale remote-tracking branches during a Fetch: This article provides procedures for the following tasks:įetch won't delete remote-tracking branches in your local repo cache that no longer have a remote counterpart. Visual Studio uses a subset of those Git commands when you synchronize your local repo with a remote repo.įor an overview of the Git workflow, see Azure Repos Git tutorial. Git pull performs a fetch and then a merge or rebase to integrate fetched commits into your current local branch.Git rebase integrates commits from a source branch into a target branch, but uses a different strategy than Git merge.Git merge integrates commits from one or more source branches into a target branch.The remote-tracking branches in local repo cache are updated-local branches remain unchanged. Git fetch downloads any new commits that others uploaded to the remote repo.These Git commands update your local repo: When there are several contributors to a project, keep your local Git repo updated by downloading and integrating work that others uploaded to the project's remote repo.
Azure DevOps Services | Azure DevOps Server 2022 - Azure DevOps Server 2019 | TFS 2018