On Jul 1, 1:53 pm, Konstantin Khomoutov <khomou...@gmail.com> wrote:
> On Jul 1, 8:00 pm, Trans <transf...@gmail.com> wrote:
> > I tried to push my tags for the first time and an old tag is throwing
> > an error:
> >   $ git push --tags
> >   To g...@github.com:proutils/vclog.git
> >    ! [rejected]        1.4.0 -> 1.4.0 (non-fast forward)
> >   error: failed to push some refs to '....@github.com:proutils/
> > vclog.git'
> > But my current tag is 1.7.0. What's going here> 1.4.0 is old. How do I
> > fix this?
> First of all, Git has no such concept as "current tag". A tag is
> simply a file which contains the name of a certain existing commit.
> Tags do not move between commits; they are "sticky" (to the commits
> they point to).
> When you do `git push --tags`, git tries to push all local tags from
> your local repository to the remote repository; any tags which are
> missing on the remote side are created there and any tags which point
> to different commits are meant to be replaced.
> Now, to be honest, I don't quite get what happens in your case: I
> always thought updating of tags cannot be rejected, and the concept of
> "fast-forward" does only apply to merges and pushing of branches. So,
> to me, this error message appears to be nonsensical.
> But I have one idea for you to explore: github may have certain hooks
> set up which prevent replacement of tags. That is, tags may be kind of
> read-only. I'm not sure if it at all possible but this would explain
> your problem. You can do several things to cope with this:
> a) Fetching from remote overwrites local tags unless you tell `git
> fetch` not to. Hence you can try to do `git fetch` and then retry your
> push.
> b) You can try to do `git push --tags --force` and see if this will
> forcibly overwrite remote tags.
> c) You can try to delete the remote tag using `git push origin :
> 1.4.0`  followed by `git push --tags`.
> What to do depends on what repo you think is correct.

Thanks. Option b did the trick. And it reminded me as to what I think

I noticed that the tag message for 1.4.0 was wrong some weeks ago, I
wasn't sure how to correct it, so I asked and a suggestion was made to
just delete the tag and retag it. So that's what I did. Even though
I'm pretty sure it's the same ref point, apparently it made a

Thanks again for the help.

You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To post to this group, send email to git-us...@googlegroups.com.
To unsubscribe from this group, send email to 
For more options, visit this group at 

Reply via email to