Changes between Version 2 and Version 3 of Basic Git Usage


Ignore:
Timestamp:
Jun 14, 2009, 4:15:38 PM (15 years ago)
Author:
Joe Ciccone
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Basic Git Usage

    v2 v3  
    121121cat testfile
    122122}}}
     123
     124=== Listing Branches ===
     125
     126The following will show you a list of branches:
     127
     128{{{
     129git branch
     130}}}
     131
     132=== Creating a tag from the current branch ===
     133
     134Before we create a tag lets change the testfile:
     135
     136{{{
     137echo "Testing Tag testing-1.0" > testfile
     138git add testfile
     139git commit -m "Change the test file before tagging."
     140}}}
     141
     142Finally create a testing-1.0 tag:
     143
     144{{{
     145git tag testing-1.0
     146}}}
     147
     148Its good to know that when you create a Tag, you stay in the current branch. It doesn't switch its current working ref to the tag. Its also good to know that when you checkout a tag, you can't commit changes to the tag. If you want to make changes you should change the branch the tag was created from or create a new branch from the tag using git checkout -b.
     149
     150=== Listing Tags ===
     151
     152The following will show you a list of tags:
     153
     154{{{
     155git tag
     156}}}