Change push command option to use --follow-tags instead of --tags - #194
Change push command option to use --follow-tags instead of --tags#194NotFounds wants to merge 1 commit into
Conversation
🦋 Changeset detectedLatest commit: 4aab3b1 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
How that has happened to you though? If I tree to
I assume that the remote tag was pointing to a different commit than your local one and it seems that it's a sign of some problem in your scripts somewhere. I think that I'm OK with changing this command but there is, of course, a slight difference there and it can bite some less conventional setups (hopefully it wouldn't affect any though). @mitchellhamilton WDYT? |
Thank you for your comment. I'll re-check my script and what is happened there. |
There's no necessary to push all tags in
refs/tags. It's enough to push only lacking tags from the remote.So we can use
--follow-tagsoption instead of--tags.cf. https://git-scm.com/docs/git-push#Documentation/git-push.txt---follow-tags
It can prevent failing workflow with the following exception:
hint: Updates were rejected because the tag already exists in the remote.