2005-09-08 02:26:23 +02:00
|
|
|
git-push(1)
|
|
|
|
===========
|
2005-08-23 10:49:47 +02:00
|
|
|
|
|
|
|
NAME
|
|
|
|
----
|
2006-03-09 17:24:50 +01:00
|
|
|
git-push - Update remote refs along with associated objects
|
2005-08-23 10:49:47 +02:00
|
|
|
|
|
|
|
|
|
|
|
SYNOPSIS
|
|
|
|
--------
|
2007-01-16 20:46:03 +01:00
|
|
|
'git-push' [--all] [--tags] [--exec=<receive-pack>] [--repo=all] [-f | --force] [-v] [<repository> <refspec>...]
|
2005-08-23 10:49:47 +02:00
|
|
|
|
|
|
|
DESCRIPTION
|
|
|
|
-----------
|
2005-08-25 01:23:08 +02:00
|
|
|
|
|
|
|
Updates remote refs using local refs, while sending objects
|
|
|
|
necessary to complete the given refs.
|
2005-08-23 10:49:47 +02:00
|
|
|
|
2006-02-06 01:42:27 +01:00
|
|
|
You can make interesting things happen to a repository
|
2005-12-05 09:32:01 +01:00
|
|
|
every time you push into it, by setting up 'hooks' there. See
|
|
|
|
documentation for gitlink:git-receive-pack[1].
|
|
|
|
|
2005-08-23 10:49:47 +02:00
|
|
|
|
|
|
|
OPTIONS
|
|
|
|
-------
|
2006-02-05 23:43:47 +01:00
|
|
|
<repository>::
|
2006-02-06 00:29:49 +01:00
|
|
|
The "remote" repository that is destination of a push
|
|
|
|
operation. See the section <<URLS,GIT URLS>> below.
|
2006-02-05 23:43:47 +01:00
|
|
|
|
|
|
|
<refspec>::
|
|
|
|
The canonical format of a <refspec> parameter is
|
|
|
|
`+?<src>:<dst>`; that is, an optional plus `+`, followed
|
|
|
|
by the source ref, followed by a colon `:`, followed by
|
|
|
|
the destination ref.
|
|
|
|
+
|
|
|
|
The <src> side can be an
|
|
|
|
arbitrary "SHA1 expression" that can be used as an
|
|
|
|
argument to `git-cat-file -t`. E.g. `master~4` (push
|
|
|
|
four parents before the current master head).
|
|
|
|
+
|
|
|
|
The local ref that matches <src> is used
|
|
|
|
to fast forward the remote ref that matches <dst>. If
|
|
|
|
the optional plus `+` is used, the remote ref is updated
|
|
|
|
even if it does not result in a fast forward update.
|
|
|
|
+
|
2006-02-22 05:28:50 +01:00
|
|
|
Note: 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), then all the
|
|
|
|
refs that exist both on the local side and on the remote
|
|
|
|
side are updated.
|
|
|
|
+
|
2006-12-13 09:59:58 +01:00
|
|
|
`tag <tag>` means the same as `refs/tags/<tag>:refs/tags/<tag>`.
|
2006-02-05 23:43:47 +01:00
|
|
|
+
|
2006-12-13 09:59:58 +01:00
|
|
|
A parameter <ref> without a colon is equivalent to
|
|
|
|
<ref>`:`<ref>, hence updates <ref> in the destination from <ref>
|
|
|
|
in the source.
|
|
|
|
+
|
|
|
|
Pushing an empty <src> allows you to delete the <dst> ref from
|
|
|
|
the remote repository.
|
2005-08-23 10:49:47 +02:00
|
|
|
|
2005-10-20 06:25:39 +02:00
|
|
|
\--all::
|
2006-02-06 01:42:27 +01:00
|
|
|
Instead of naming each ref to push, specifies that all
|
|
|
|
refs be pushed.
|
2005-10-20 06:25:39 +02:00
|
|
|
|
2006-01-16 08:27:34 +01:00
|
|
|
\--tags::
|
|
|
|
All refs under `$GIT_DIR/refs/tags` are pushed, in
|
|
|
|
addition to refspecs explicitly listed on the command
|
|
|
|
line.
|
|
|
|
|
2007-01-16 16:02:02 +01:00
|
|
|
\--exec::
|
|
|
|
Path to the 'git-receive-pack' program on the remote
|
|
|
|
end. Sometimes useful when pushing to a remote
|
|
|
|
repository over ssh, and you do not have the program in
|
|
|
|
a directory on the default $PATH.
|
|
|
|
|
2005-10-20 06:25:39 +02:00
|
|
|
-f, \--force::
|
2006-01-30 02:40:50 +01:00
|
|
|
Usually, the command refuses to update a remote ref that is
|
2006-07-09 09:44:30 +02:00
|
|
|
not a descendant of the local ref used to overwrite it.
|
2006-01-30 02:40:50 +01:00
|
|
|
This flag disables the check. This can cause the
|
|
|
|
remote repository to lose commits; use it with care.
|
2005-08-23 10:49:47 +02:00
|
|
|
|
2007-01-16 20:46:03 +01:00
|
|
|
\--repo=<repo>::
|
|
|
|
When no repository is specified the command defaults to
|
|
|
|
"origin"; this overrides it.
|
|
|
|
|
|
|
|
\--thin, \--no-thin::
|
|
|
|
These options are passed to `git-send-pack`. Thin
|
|
|
|
transfer spends extra cycles to minimize the number of
|
|
|
|
objects to be sent and meant to be used on slower connection.
|
|
|
|
|
|
|
|
-v::
|
|
|
|
Run verbosely.
|
|
|
|
|
2006-02-06 00:29:49 +01:00
|
|
|
include::urls.txt[]
|
2005-12-05 09:32:01 +01:00
|
|
|
|
2005-08-23 10:49:47 +02:00
|
|
|
Author
|
|
|
|
------
|
2006-12-13 09:59:58 +01:00
|
|
|
Written by Junio C Hamano <junkio@cox.net>, later rewritten in C
|
|
|
|
by Linus Torvalds <torvalds@osdl.org>
|
2005-08-23 10:49:47 +02:00
|
|
|
|
|
|
|
Documentation
|
|
|
|
--------------
|
|
|
|
Documentation by Junio C Hamano and the git-list <git@vger.kernel.org>.
|
|
|
|
|
|
|
|
GIT
|
|
|
|
---
|
2005-09-19 12:10:51 +02:00
|
|
|
Part of the gitlink:git[7] suite
|
2005-08-23 10:49:47 +02:00
|
|
|
|