Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions book/02-git-basics/sections/tagging.asc
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ If, however, you're supplying a wildcard pattern to match tag names, the use of

Git supports two types of tags: _lightweight_ and _annotated_.

A lightweight tag is very much like a branch that doesn't change it's just a pointer to a specific commit.
A lightweight tag is very much like a branch that doesn't change -- it's just a pointer to a specific commit.

Annotated tags, however, are stored as full objects in the Git database.
They're checksummed; contain the tagger name, email, and date; have a tagging message; and can be signed and verified with GNU Privacy Guard (GPG).
Expand Down Expand Up @@ -100,7 +100,7 @@ That shows the tagger information, the date the commit was tagged, and the annot

(((tags, lightweight)))
Another way to tag commits is with a lightweight tag.
This is basically the commit checksum stored in a file no other information is kept.
This is basically the commit checksum stored in a file -- no other information is kept.
To create a lightweight tag, don't supply any of the `-a`, `-s`, or `-m` options, just provide a tag name:

[source,console]
Expand Down Expand Up @@ -187,7 +187,7 @@ Date: Sun Apr 27 20:43:35 2008 -0700

By default, the `git push` command doesn't transfer tags to remote servers.(((git commands, push)))
You will have to explicitly push tags to a shared server after you have created them.
This process is just like sharing remote branches you can run `git push origin <tagname>`.
This process is just like sharing remote branches -- you can run `git push origin <tagname>`.

[source,console]
----
Expand Down Expand Up @@ -242,7 +242,7 @@ Previous HEAD position was 99ada87... Merge pull request #89 from schacon/append
HEAD is now at df3f601... add atlas.json and cover image
----

In ``detached HEAD'' state, if you make changes and then create a commit, the tag will stay the same, but your new commit won't belong to any branch and will be unreachable, except for by the exact commit hash. Thus, if you need to make changessay you're fixing a bug on an older version, for instanceyou will generally want to create a branch:
In ``detached HEAD'' state, if you make changes and then create a commit, the tag will stay the same, but your new commit won't belong to any branch and will be unreachable, except for by the exact commit hash. Thus, if you need to make changes -- say you're fixing a bug on an older version, for instance -- you will generally want to create a branch:

[source,console]
----
Expand Down