Use current "detached HEAD" message
Signed-off-by: Thomas Ackermann <th.acker@arcor.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Thomas Ackermann committed
Aug 27, 2013 at 19:56 UTC
95f9be556dad9e4a92bbfed30d5ef01a5fd9df3a
1 file changed
+13
-6
Documentation/user-manual.txt
+13
-6
@@ -312,10 +312,17 @@ referenced by a tag:
312
313
------------------------------------------------
314
$ git checkout v2.6.17
315
-Note: moving to "v2.6.17" which isn't a local branch
316
-If you want to create a new branch from this checkout, you may do so
317
-(now or later) by using -b with the checkout command again. Example:
318
- git checkout -b <new_branch_name>
315
+Note: checking out 'v2.6.17'.
316
+
317
+You are in 'detached HEAD' state. You can look around, make experimental
318
+changes and commit them, and you can discard any commits you make in this
319
+state without impacting any branches by performing another checkout.
320
+
321
+If you want to create a new branch to retain commits you create, you may
322
+do so (now or later) by using -b with the checkout command again. Example:
323
+
324
+ git checkout -b new_branch_name
325
+
326
HEAD is now at 427abfa... Linux v2.6.17
327
------------------------------------------------
328
@@ -326,7 +333,7 @@ and git branch shows that you are no longer on a branch:
333
$ cat .git/HEAD
334
427abfa28afedffadfca9dd8b067eb6d36bac53f
335
$ git branch
329
-* (no branch)
336
+* (detached from v2.6.17)
337
master
338
------------------------------------------------
339
@@ -3639,7 +3646,7 @@ working on a branch.
3646
3647
-------------------------------------------------
3648
$ git branch
3642
-* (no branch)
3649
+* (detached from d266b98)
3650
master
3651
-------------------------------------------------
3652