how to update remote branches list git

C++
git remote update origin --prune

Source

Also in C++: