@ -622,7 +622,7 @@ We have seen several ways of naming commits already:
@@ -622,7 +622,7 @@ We have seen several ways of naming commits already:
- HEAD: refers to the head of the current branch
There are many more; see the "SPECIFYING REVISION" section of the
gitlink:git-rev-list[1] man page for the complete list of ways to
gitlink:git-rev-parse[1] man page for the complete list of ways to
name revisions. Some examples:
-------------------------------------------------
@ -663,6 +663,15 @@ When we discuss merges we'll also see the special name MERGE_HEAD,
@@ -663,6 +663,15 @@ When we discuss merges we'll also see the special name MERGE_HEAD,
which refers to the other branch that we're merging in to the current
branch.
The gitlink:git-rev-parse[1] command is a low-level command that is
occasionally useful for translating some name for a commit to the SHA1 id for
that commit:
-------------------------------------------------
$ git rev-parse origin
e05db0fd4f31dde7005f075a84f96b360d05984b
-------------------------------------------------
Creating tags
-------------
@ -757,6 +766,47 @@ $ git show v2.5:fs/locks.c
@@ -757,6 +766,47 @@ $ git show v2.5:fs/locks.c
Before the colon may be anything that names a commit, and after it
may be any path to a file tracked by git.
Examples
--------
Check whether two branches point at the same history