Will assigning at tag to a Github Release also assign it to the Commit

我是研究僧i 提交于 2019-12-24 12:06:09

问题


Will assigning at tag (e.g. v1.1.0) to a Github release also assign it to the commit, assuming that the specified commit doesn't already have a tag? If so, will it be a lightweight or annotated tag?


回答1:


Will assigning at tag (e.g. v1.1.0) to a Github release also assign it to the commit

Yes it will.

If so, will it be a lightweight or annotated tag?

A lightweight one.


You can take a look at this sample release that I've created through GitHub UI for the sake of answering this question. This repository wasn't previously bearing any tag.

Once locally fetched, one can see that a new tag has been added upstream.

$ ls .git/refs/tags/
v0.1

And that this tag directly points to a commit (ie. It's a lightweight tag, not an annotated one).

$ cat .git/refs/tags/v0.1
485750d2def0e01f5653534659d1785be0ff73db

$ git cat-file -t 48575
commit


来源:https://stackoverflow.com/questions/23048947/will-assigning-at-tag-to-a-github-release-also-assign-it-to-the-commit

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!