Jūs esate

git

How to delete a tag in GIT?

You create a tag in GIT, accidentally pushed it into remote repository. But after some time you understood that you don't want it. So, how can you remove a tag in GIT?

You can do this easily by:
git tag -d NAME_OF_YOUR_BAD_TAG
git push origin :refs/tags/NAME_OF_YOUR_BAD_TAG

The first command deletes this tag from your local repository, the second - from remote repository.

How to revert changes in file in GIT?

You have edited one file in GIT version control system and you want to reset (revert) changes in this file. How can you do that?

Everything is simple: use checkout -- in command line. For instance:

git checkout -- path/to/file/my_changed_file.txt

Subscribe to git