Buy All 78 Premium WordPress Themes for $59.99
No Additional Fees, Pay Once and Use Unlimited Time for Unlimited Domains, Free Lifetime Updates

Apply a Hotfix to an existing Github tag

Sometimes I need to apply a hotfix to an existing github tag. Instead of creating a new tag and new release it can be done to the existing one. Here are all of the steps:

Prerequisite would be to make sure you have already committed and push all new changes to the main/master branch.

Open terminal and navigate to the local repo folder

Get list of existing tags by executing:

git tag

example output:


we need to update the latest tag ‘release-22.4.0’. It will be listed at the end of the list.

First we need to delete the tag locally

git tag -d release-22.4.0

Then we need to delete the tag remotely:

git push --delete origin release-22.4.0

After that we can re-create the tag locally (it will include the latest changes from the main/master branch):

git tag release-22.4.0

And then we need to push the tag:

git push --tags

Also, if there is a Github Release created from that on, it will be in status ‘Draft’. You need to open the repo in, navigate to ‘Releases’ and publish the tag.

Leave a Reply