There is a branch A in the remote, and I can git branch -r
view all branches in the remote, including branch A.
Now the administrator has deleted the remote branch A, and now I check git branch -r
all the branches of the remote warehouse in the local warehouse and found that branch A has not been deleted.
So I thought of using it to git fetch origin
update the remote local cache, and then check all the remote branches, and found that the update failed. (The addition of the remote branch can be git fetch
updated, but the deletion does not seem to be updated.)
I tried the following command and found that the update was successful.
git remote update origin --prune