Skip to content

Commit

Permalink
user-manual: give 'git push -f' as an alternative to +master
Browse files Browse the repository at this point in the history
This mirrors existing language in the description of 'git fetch'.

Signed-off-by: W. Trevor King <wking@tremily.us>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
W. Trevor King authored and Junio C Hamano committed Feb 18, 2013
1 parent e9b4908 commit d1471e0
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Documentation/user-manual.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2045,6 +2045,13 @@ branch name with a plus sign:
$ git push ssh://yourserver.com/~you/proj.git +master
-------------------------------------------------

Note the addition of the `+` sign. Alternatively, you can use the
`-f` flag to force the remote update, as in:

-------------------------------------------------
$ git push -f ssh://yourserver.com/~you/proj.git master
-------------------------------------------------

Normally whenever a branch head in a public repository is modified, it
is modified to point to a descendant of the commit that it pointed to
before. By forcing a push in this situation, you break that convention.
Expand Down

0 comments on commit d1471e0

Please sign in to comment.