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

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root


1 badge earned


Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!


Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.


Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!


Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
Community Members
Community Events
Community Groups

Is it okay that .hgtags exists in default branch, but not in develop branch?


In one of my repos, when I check out my default branch, I see an .hgtags file there. But it disappears when I check out my develop branch. Is this a problem?

1 answer

0 votes
minnsey Atlassian Team Oct 22, 2018


.hgtags contains the global tag names. It is a version controlled file so it should be in your repository, but depending on when it was created vs the develop branch it is possible it is in one branch but not the other.

I imagine that if I add a tag to my develop branch, I will magically get a .hgtags file for that branch. I don't add tags to the develop branch, as a rule. Only to the default branch to track version numbers. But repositories where I *do* have an .hgtags file in develop, show it has only the initial commit version number tag in it, where the default branch .hgtags has all the tags I use for version numbers in default.

What would happen if I copy the .hgtags file I see in the default branch into my develop branch?

The reason I ask is that, because my develop branch lacks an .hgtags file, I always have to make sure that the last Push I do from my MacBook Pro is with a changeset in my develop branch. Otherwise when I do a Pull on my Mac Mini, I'm told that

hg cat' failed with code 1:'.hgtags: no such file in rev ...

Or should I just create a tag on my develop branch?


I see now why this happened, as you can see in the above image. I mistakenly created the develop branch BEFORE committing the initial tag creation. Will this Pull problem go away if I just add a tag to my most recent develop changeset?

minnsey Atlassian Team Dec 07, 2018

To be honest I don't know, it might be a question the Mercurial mailing lists can answer better.

But I can't see any downside to trying.

Sorry its not a definitive answer.

Thanks for your time on this, Michael.

I checked out the tip of develop and then added a tag to the first develop changeset. So that tag now appears on the first develop changeset and in the left column of tags.

I then merged develop to default and resolved the conflict on .hgtags to keep "Mine". When I do this, however, the tag disappears on the first develop changeset and disappears from the left column of tags.

However, develop now has a .hgtags file with that single tag referencing the first develop changeset and I don't get the Pull problems I was having before. But I'm concerned about the tag no longer appearing in Sourcetree. So I'm reticent to actually do this with my production repository. I did all this on a test local/remote repository.

I'm tempted to create a new repository for this code and do it properly this time, so develop is created AFTER I create my first default tag.

I resolved this by simply copying my latest source code over to a new folder and created a repository there, properly this time. I can always go back to the prior repo if I need to access older versions of this source code.

Suggest an answer

Log in or Sign up to answer

Atlassian Community Events