Moving Tags in SourceTree


I have an existing tag on the remote server.  When I want to move the tag by right clicking a different commit and selecting "Tag...", expanding Advanced Options and selecting Move Tag, the tag is successfully moved on the server and my local repository.

However, other users do not see the tag moved in SourceTree, even after refreshing and pulling local changes.  If the other user opens a terminal and does git fetch --tags, then the tag is successfully moved.  Why isn't SourceTree automatically showing the tag as moved?



1 answer

To fix the issue, your teammates should delete their local copies of the tag, then Fetch (make sure Fetch All Tags option is checked).

In Git, tags are not designed to be moved. It certainly provides the functionality (mistakes happen), but it should not be part of your normal workflow to move tags. If you need some sort of commit reference that can move to different commits, that's called a branch.

The reason your teammates aren't seeing their tags move is precisely because tags are not designed to be moved. A fetch operation can create new local tags that duplicate tags on the remote. Local tags cannot be modified by the remote. This has two symptoms. First (as you've noticed), your teammates copies of the tag continue to point to the original commit. Secondly, if your teammates attempt to push their tags, the operation will FAIL (the central server interprets that as the pushing server trying to push a duplicate tag).


Suggest an answer

Log in or Sign up to answer
Community showcase
Published Nov 06, 2018 in Bitbucket

Upgrade Best Practices

Hello! My name is Mark Askew and I am a Premier Support Engineer for products Bitbucket Server/Data Center, Fisheye & Crucible. Today, I want to bring the discussion that Jennifer, Matt, and ...

844 views 5 10
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you