remove_redundant_remotes

Function remove_redundant_remotes 

Source
pub fn remove_redundant_remotes(branches: &mut Vec<Branch>)
Expand description

Removes remote branches that have a corresponding local branch of the same shortened name.

A remote branch is considered redundant if its name after the first / (e.g. origin/feature-x -> feature-x) matches a local branch name.

After this function returns, each remaining Branch::Remote has no local counterpart with the same short name.