Documentation/tutorial: misc updates
- Teach how to delete a branch with "git branch -d name". - Usually a commit has one parent; merge has more. - Teach "git show" instead of "git cat-file -p". Signed-off-by: Santi Béjar <sbejar@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
Santi Béjar committed
Jan 3, 2007 at 13:53 UTC
9c9410e115add56bc33a57f16c7e64da2e1fb0ec
1 file changed
+13
-4
Documentation/tutorial.txt
+13
-4
@@ -232,6 +232,15 @@ $ gitk
232
233
will show a nice graphical representation of the resulting history.
234
235
+At this point you could delete the experimental branch with
236
+
237
+------------------------------------------------
238
+$ git branch -d experimental
239
+------------------------------------------------
240
+
241
+This command ensures that the changes in the experimental branch are
242
+already in the current branch.
243
+
244
If you develop on a branch crazy-idea, then regret it, you can always
245
delete the branch with
246
@@ -401,8 +410,8 @@ $ git show HEAD # the tip of the current branch
410
$ git show experimental # the tip of the "experimental" branch
411
-------------------------------------
412
404
-Every commit has at least one "parent" commit, which points to the
405
-previous state of the project:
413
+Every commit usually has one "parent" commit
414
+which points to the previous state of the project:
415
416
-------------------------------------
417
$ git show HEAD^ # to see the parent of HEAD
@@ -520,10 +529,10 @@ of the file:
529
$ git diff v2.5:Makefile HEAD:Makefile.in
530
-------------------------------------
531
523
-You can also use "git cat-file -p" to see any such file:
532
+You can also use "git show" to see any such file:
533
534
-------------------------------------
526
-$ git cat-file -p v2.5:Makefile
535
+$ git show v2.5:Makefile
536
-------------------------------------
537
538
Next Steps