~ubuntu-branches/debian/sid/git/sid

« back to all changes in this revision

Viewing changes to Documentation/git-push.txt

  • Committer: Package Import Robot
  • Author(s): Gerrit Pape
  • Date: 2012-06-08 00:04:11 UTC
  • mfrom: (1.2.18)
  • Revision ID: package-import@ubuntu.com-20120608000411-4oljtllc9gst19ou
Tags: 1:1.7.10.4-1
new upstream point release (thx Jonathan Nieder).

Show diffs side-by-side

added added

removed removed

Lines of Context:
34
34
 
35
35
<refspec>...::
36
36
        The format of a <refspec> parameter is an optional plus
37
 
        `{plus}`, followed by the source ref <src>, followed
 
37
        `+`, followed by the source ref <src>, followed
38
38
        by a colon `:`, followed by the destination ref <dst>.
39
39
        It is used to specify with what <src> object the <dst> ref
40
40
        in the remote repository is to be updated.
50
50
+
51
51
The object referenced by <src> is used to update the <dst> reference
52
52
on the remote side, but by default this is only allowed if the
53
 
update can fast-forward <dst>.  By having the optional leading `{plus}`,
 
53
update can fast-forward <dst>.  By having the optional leading `+`,
54
54
you can tell git to update the <dst> ref even when the update is not a
55
55
fast-forward.  This does *not* attempt to merge <src> into <dst>.  See
56
56
EXAMPLES below for details.
60
60
Pushing an empty <src> allows you to delete the <dst> ref from
61
61
the remote repository.
62
62
+
63
 
The special refspec `:` (or `{plus}:` to allow non-fast-forward updates)
 
63
The special refspec `:` (or `+:` to allow non-fast-forward updates)
64
64
directs git to push "matching" branches: for every branch that exists on
65
65
the local side, the remote side is updated if a branch of the same name
66
66
already exists on the remote side.  This is the default operation mode
75
75
        Remove remote branches that don't have a local counterpart. For example
76
76
        a remote branch `tmp` will be removed if a local branch with the same
77
77
        name doesn't exist any more. This also respects refspecs, e.g.
78
 
        `git push --prune remote refs/heads/{asterisk}:refs/tmp/{asterisk}` would
 
78
        `git push --prune remote refs/heads/*:refs/tmp/*` would
79
79
        make sure that remote `refs/tmp/foo` will be removed if `refs/heads/foo`
80
80
        doesn't exist.
81
81
 
204
204
flag::
205
205
        A single character indicating the status of the ref:
206
206
(space);; for a successfully pushed fast-forward;
207
 
`{plus}`;; for a successful forced update;
 
207
`+`;; for a successful forced update;
208
208
`-`;; for a successfully deleted ref;
209
209
`*`;; for a successfully pushed new ref;
210
210
`!`;; for a ref that was rejected or failed to push; and
214
214
        For a successfully pushed ref, the summary shows the old and new
215
215
        values of the ref in a form suitable for using as an argument to
216
216
        `git log` (this is `<old>..<new>` in most cases, and
217
 
        `<old>\...<new>` for forced non-fast-forward updates).
 
217
        `<old>...<new>` for forced non-fast-forward updates).
218
218
+
219
219
For a failed update, more details are given:
220
220
+
396
396
        Find a ref that matches `experimental` in the `origin` repository
397
397
        (e.g. `refs/heads/experimental`), and delete it.
398
398
 
399
 
`git push origin {plus}dev:master`::
 
399
`git push origin +dev:master`::
400
400
        Update the origin repository's master branch with the dev branch,
401
401
        allowing non-fast-forward updates.  *This can leave unreferenced
402
402
        commits dangling in the origin repository.*  Consider the