Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I create a tag in GitHub without creating a release?

Tags:

github

git-tag

I am about to make a major technology change to my project, moving from ANT to Gradle. There has never been a release of this project -- it is still in development. I would like to tag the last old technology version so that it can be found for reference or reversion. But I don't want to imply that there is any kind of release.

[AN ADDED THOUGHT: I would expect some interested person to see a release and think that it might be a usable "release". That is, I'm thinking releases are for users and tags are for developers. ]

I would prefer an answer that does not require me to drop into the Git command line, but if that's necessary, please assume that I have forgotten what little I ever did attempt to learn.

In a comment on an answer to the question create-a-tag-in-a-github-repository, @RandomDSdevel says:

[S]houldn't you be able to create tags that don't automatically get picked up by GitHub as releases…?

Then

I submitted a support request to GitHub about this a while ago, but they had a bit of a support backlog back then, so my request was closed.

like image 238
cowang Avatar asked Mar 12 '26 21:03

cowang


2 Answers

The easiest solution would be to create a release (in the GitHub UI), and then delete the release.
This will only delete the release, but the tag will remain still, which would be the solution to your problem.

Hope this is useful to you. 🙂

like image 155
Panquesito7 Avatar answered Mar 15 '26 17:03

Panquesito7


Summarizing my experience so far using GitHub to create a tag without a release:

I can create a release, but it requires my tag name to have a version at the start, like

v0.0-MyTagName

If I delete the release, the tag still shows up under the list of tags (and the list of releases, but at least it doesn't show up in the headline type that it did as a release).

At this point I can edit the tag name to get rid of the "v0.0-", leaving the name that I really want. It looks like it switches you to editing a release, but it stays as a tag unless you add a title. Now it doesn't look like a release, even though the tag name shows up in the list of releases.

Using git instead of GitHub, you may be able to do more.

I could not find the tags or releases in GitHub Desktop. If you just want to look at the code at a branch, you will have to do that online. If you want to modify the code at the tag, you need to create a branch, of course. Branches are visible in GitHub Desktop.

like image 32
cowang Avatar answered Mar 15 '26 16:03

cowang