samuelabate
samuelabate

Reputation: 1631

Numbers on the push and pull button of SourceTree won't change

I started using SourceTree few days ago and after I committed and pushed my changes to the remote GitHub repository, the numbers on the buttons remain the same, for example if the number on the push button becomes 3 when I committed a change, after I pushed it; it needs to be 0 or empty. But that's not the case here, it remains the same even though it has successfully been pushed. I also checked that my changes had been pushed using a web browser by going to the GitHub site. Is it because of the branch that I have pulled from and am pushing to are different or something else? Can any one please help cause I don't understand it... Thanks!

Upvotes: 4

Views: 8329

Answers (3)

John Lewin
John Lewin

Reputation: 6230

The numbers shown on the right hand side of the Branches panel reflect how many commits ahead or behind the Tracking Branch you currently are. If the numbers aren't what you expect, you should verify that the branch is tracking what you actually want.

You can verify the tracking branch by right clicking your local branch (as depicted below) and expanding the Track remote branch menu item. Finally, if you want to change the tracking branch simply click the new target from the list and Sourcetree will update accordingly. Hopefully that helps make sense of the disconnect that can happen when you rename branches and provides some details around why it happens and a simple way to resolve.

tracking-branch-example

Upvotes: 4

Antoine
Antoine

Reputation: 880

I simply use the keyboard shortcut from the Repository menu:

CTRL+ALT+R (or control+option+R if you prefer)

My guess is that the shortcut would be the same or at least similar on Windows. Just look for the option called Refresh Remote Status under the Repository menu.

Upvotes: 0

Tiago Mendes
Tiago Mendes

Reputation: 5156

The same thing also happened to me too, I was working on branch I had push everting but was keeping appearing one unsend Push and miraculously also appear unsend Push on Master. So what did was the same as Hristo Staykov and Sammie remove the Master branch from my local computer, since I had one miraculously unsend Push on Master did need to run this line terminal to remove the branch:

git branch -D master

And then Repository > Refresh Remote Status

Upvotes: 2

Related Questions