O'Reilly logo

Pragmatic Version Control Using Git by Travis Swicegood

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Handling Releases

Your code is ready for its 1.0 release. It’s time to tag it. Tagging code in Git marks a specific point in the history of the repository so you can refer to it easily. Since this is the 1.0 release, tag it with that number:

 
prompt>​ git tag 1.0 RB_1.0

The two parameters specify the name of the tag and the point you want to tag: 1.0 and the branch RB_1.0, respectively. You can view a list of tags in your repository by running git tag without any parameters. Right now, it shows only the 1.0 tag you just created:

 
prompt>​ git tag
 
1.0

Now that your code is tagged, you need to perform some cleanup. You have two branches, and each contains commits that the other does not know about. The master branch—the branch you started ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required