Documentation: rework src/dst description in git push
This tries to make the description of ref matching in git push easier to read. Beauty is in the eye of the beholder, though. Signed-off-by: Anders Melchiorsen <mail@cup.kalibalik.dk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Anders Melchiorsen committed
Jan 26, 2009 at 00:45 UTC
803918462e58005d18c0ab63686dbd9e91330dfe
1 file changed
+12
-11
Documentation/git-push.txt
+12
-11
@@ -39,20 +39,21 @@ OPTIONS
39
It is used to specify with what <src> object the <dst> ref
40
in the remote repository is to be updated.
41
+
42
-The <src> side represents the source branch (or arbitrary
43
-"SHA1 expression", such as `master~4` (four parents before the
44
-tip of `master` branch); see linkgit:git-rev-parse[1]) that you
45
-want to push. The <dst> side represents the destination location.
42
+The <src> is often the name of the branch you would want to push, but
43
+it can be any arbitrary "SHA-1 expression", such as `master~4` or
44
+`HEAD` (see linkgit:git-rev-parse[1]).
45
+
47
-The local ref that matches <src> is used
48
-to fast forward the remote ref that matches <dst>. If
49
-the optional leading plus `+` is used, the remote ref is updated
50
-even if it does not result in a fast forward update.
46
+The <dst> tells which ref on the remote side is updated with this
47
+push. Arbitrary expressions cannot be used here, an actual ref must
48
+be named. If `:`<dst> is omitted, the same ref as <src> will be
49
+updated.
50
+
52
-`tag <tag>` means the same as `refs/tags/<tag>:refs/tags/<tag>`.
51
+The object referenced by <src> is used to fast forward the ref <dst>
52
+on the remote side. If the optional leading plus `{plus}` is used, the
53
+remote ref is updated even if it does not result in a fast forward
54
+update.
55
+
54
-A lonely <src> parameter (without a colon and a destination) pushes
55
-the <src> to the same name in the destination repository.
56
+`tag <tag>` means the same as `refs/tags/<tag>:refs/tags/<tag>`.
57
+
58
Pushing an empty <src> allows you to delete the <dst> ref from
59
the remote repository.