aboutsummaryrefslogtreecommitdiff
path: root/README
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2005-11-15 01:31:04 -0800
committerJunio C Hamano <junkio@cox.net>2005-11-15 01:31:04 -0800
commitcd0a781c386b197e63a30104bead39420eada7ca (patch)
tree8ea8ba4b812ca2bc384ccc117da7fd4f4516f000 /README
parent313c4714c5ec1673805b952ba79d910a42e8937c (diff)
downloadgit-cd0a781c386b197e63a30104bead39420eada7ca.tar.gz
git-cd0a781c386b197e63a30104bead39420eada7ca.tar.xz
Documentation: do not blindly run 'cat' .git/HEAD, or echo into it.
Many places in the documentation we still talked about reading what commit is recorded in .git/HEAD or writing the new head information into it, both assuming .git/HEAD is a symlink. That is not necessarily so. Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'README')
-rw-r--r--README6
1 files changed, 3 insertions, 3 deletions
diff --git a/README b/README
index 4a2616ba5..36fef6ec0 100644
--- a/README
+++ b/README
@@ -396,8 +396,8 @@ git-commit-tree will return the name of the object that represents
that commit, and you should save it away for later use. Normally,
you'd commit a new `HEAD` state, and while git doesn't care where you
save the note about that state, in practice we tend to just write the
-result to the file `.git/HEAD`, so that we can always see what the
-last committed state was.
+result to the file pointed at by `.git/HEAD`, so that we can always see
+what the last committed state was.
Here is an ASCII art by Jon Loeliger that illustrates how
various pieces fit together.
@@ -464,7 +464,7 @@ tend to be small and fairly self-explanatory. In particular, if you
follow the convention of having the top commit name in `.git/HEAD`,
you can do
- git-cat-file commit $(cat .git/HEAD)
+ git-cat-file commit HEAD
to see what the top commit was.