From 98347fee9bbff2676dff39895f9419b129d92e43 Mon Sep 17 00:00:00 2001 From: Anders Melchiorsen Date: Sun, 18 Jan 2009 15:36:55 +0100 Subject: [PATCH 1/4] Documentation: git push repository can also be a remote This is copied from pull-fetch-param.txt and helps the reader to not get stuck in the URL section. Signed-off-by: Anders Melchiorsen Signed-off-by: Junio C Hamano --- Documentation/git-push.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Documentation/git-push.txt b/Documentation/git-push.txt index 3321966c6b..8bfa7cb7e5 100644 --- a/Documentation/git-push.txt +++ b/Documentation/git-push.txt @@ -28,7 +28,9 @@ OPTIONS ------- :: The "remote" repository that is destination of a push - operation. See the section <> below. + operation. This parameter can be either a URL + (see the section <> below) or the name + of a remote (see the section <> below). ...:: The canonical format of a parameter is From 391d186babf9761f73d367c7325bc5c3d4e1495d Mon Sep 17 00:00:00 2001 From: Anders Melchiorsen Date: Sun, 18 Jan 2009 15:36:56 +0100 Subject: [PATCH 2/4] Documentation: remove a redundant elaboration The comment in parentheses is wrong, as one has to leave out both the colon and . This situation is covered by the section a few lines down: A parameter without a colon pushes the from the source repository to the destination repository under the same name. So, just remove the parentheses. Signed-off-by: Anders Melchiorsen Signed-off-by: Junio C Hamano --- Documentation/git-push.txt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Documentation/git-push.txt b/Documentation/git-push.txt index 8bfa7cb7e5..6d3c711de6 100644 --- a/Documentation/git-push.txt +++ b/Documentation/git-push.txt @@ -44,8 +44,7 @@ tip of `master` branch); see linkgit:git-rev-parse[1]) that you want to push. The side represents the destination location. + The local ref that matches is used -to fast forward the remote ref that matches (or, if no was -specified, the same ref that referred to locally). If +to fast forward the remote ref that matches . If the optional leading plus `+` is used, the remote ref is updated even if it does not result in a fast forward update. + From 89edd5a90134fc265940499e33f431b1a7102693 Mon Sep 17 00:00:00 2001 From: Anders Melchiorsen Date: Sun, 18 Jan 2009 15:36:57 +0100 Subject: [PATCH 3/4] Documentation: mention branches rather than heads The "matching refs" semantics works only on matching branches these days. Instead of using "heads" which traditionally has been used more or less interchangeably with "refs", say "branch" explicitly here. Signed-off-by: Anders Melchiorsen Signed-off-by: Junio C Hamano --- Documentation/git-push.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/git-push.txt b/Documentation/git-push.txt index 6d3c711de6..a7a6f4cdef 100644 --- a/Documentation/git-push.txt +++ b/Documentation/git-push.txt @@ -57,8 +57,8 @@ Pushing an empty allows you to delete the ref from the remote repository. + The special refspec `:` (or `+:` to allow non-fast forward updates) -directs git to push "matching" heads: for every head that exists on -the local side, the remote side is updated if a head of the same name +directs git to push "matching" branches: for every branch that exists on +the local side, the remote side is updated if a branch of the same name already exists on the remote side. This is the default operation mode if no explicit refspec is found (that is neither on the command line nor in any Push line of the corresponding remotes file---see below). From 69274b6e8791824489eb5cf0a25b7577cd2a77c1 Mon Sep 17 00:00:00 2001 From: Anders Melchiorsen Date: Sun, 18 Jan 2009 15:36:58 +0100 Subject: [PATCH 4/4] Documentation: avoid using undefined parameters The parameter has not been introduced, so rewrite to avoid it. Signed-off-by: Anders Melchiorsen Signed-off-by: Junio C Hamano --- Documentation/git-push.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/git-push.txt b/Documentation/git-push.txt index a7a6f4cdef..7b27dc60bd 100644 --- a/Documentation/git-push.txt +++ b/Documentation/git-push.txt @@ -50,8 +50,8 @@ even if it does not result in a fast forward update. + `tag ` means the same as `refs/tags/:refs/tags/`. + -A parameter without a colon pushes the from the source -repository to the destination repository under the same name. +A lonely parameter (without a colon and a destination) pushes +the to the same name in the destination repository. + Pushing an empty allows you to delete the ref from the remote repository.