Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Moving Tags in SourceTree

Kris Parrent October 21, 2016

Hello,

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?

Thanks,

Kris

1 answer

0 votes
Seth
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 21, 2016

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
TAGS
AUG Leaders

Atlassian Community Events