Brandon Casey <> writes:

> From: Brandon Casey <>
> This example in the documentation seems to be trying to describe the likely
> remote tracking branch that will be updated by a push to the "origin" remote
> with the destination branch 'satellite/master', but it forgot to specify
> the remote name in the path specification.
> So,
>    refs/remotes/satellite/master
> should be spelled like
>    refs/remotes/origin/satellite/master

I might make sense to rename 'origin' to 'mothership' in that
example and explain that this is emulating 'git fetch' run on the
mothership to integrate the work done on 'satellite' using 'git
push' in the opposite direction, which is often necessary when you
can only make connection in one way (i.e. satellite can ssh into
mothership but mothership cannot initiate connection to satellite
because the latter is behind a firewall or does not run sshd).

If you were to run 'git fetch' on the mothership to intgrate the
work on the 'satellite', it would have a remote called 'satellite',
and would keep remote-tracking branches for the branches local to
'satellite' in the 'refs/remotes/satellite/' hierarchy.  You would
push your local 'master' to their 'refs/remotes/satellite/master',
to emulate 'git fetch' done on the mothership in the reverse

So refs are correct. The context is not sufficiently explained.

> Signed-off-by: Brandon Casey <>
> ---
>  Documentation/git-push.txt |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
> diff --git a/Documentation/git-push.txt b/Documentation/git-push.txt
> index fe46c42..a18f929 100644
> --- a/Documentation/git-push.txt
> +++ b/Documentation/git-push.txt
> @@ -387,8 +387,8 @@ the ones in the examples below) can be configured as the 
> default for
>  `git push origin master:satellite/master dev:satellite/dev`::
>       Use the source ref that matches `master` (e.g. `refs/heads/master`)
>       to update the ref that matches `satellite/master` (most probably
> -     `refs/remotes/satellite/master`) in the `origin` repository, then
> -     do the same for `dev` and `satellite/dev`.
> +     `refs/remotes/origin/satellite/master`) in the `origin` repository,
> +     then do the same for `dev` and `satellite/dev`.
>  `git push origin HEAD:master`::
>       Push the current branch to the remote ref matching `master` in the
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to
More majordomo info at

Reply via email to