X-Git-Url: https://oss.titaniummirror.com/gitweb?a=blobdiff_plain;f=git-publish-branch.1;h=502399e79fe1aa30b37db1390ca02666b4d3dff8;hb=HEAD;hp=c16e5d94d11113c4f05c5043fa90f8c3c2037378;hpb=4b01965a29349eb340282f32bc37097050ec25b9;p=git-utils.git diff --git a/git-publish-branch.1 b/git-publish-branch.1 index c16e5d9..502399e 100644 --- a/git-publish-branch.1 +++ b/git-publish-branch.1 @@ -4,27 +4,35 @@ git-publish-branch \- publish a local branch to a remote repository .SH SYNOPSIS -\fBgit-publish-branch\fR [-d|-h] [\fIBRANCH\fR] [\fIREPOSITORY\fR] +\fBgit-publish-branch\fR [-d] [-f] [\fIBRANCH\fR] [\fIREPOSITORY\fR] .SH "DESCRIPTION" .PP \fBgit-publish-branch\fR publishes a local branch to a remote repository. The selected branch is pushed to the remote repository and the local branch is -reset as a tracking branch for the new remote branch. +reset as a tracking branch for the new remote branch. Subsequent calls to +\fBgit-publish-branch\fR peform fast-forward updates of the remote branch by +pushing new commits in the local branch. If the -d option is specified, the branch is removed from the remote repository and the local branch is unset as its tracking branch. +If the -f option is specified, allows a non-fast forward update of the remote +branch, as supported by adding a '+' to the refspec on a git push command. +BE CAREFUL, as this command will lose history on the remote branch. The -f +option is only suitable for pushing topic or temporary branches that are +periodically rebased, and other users of the branch are aware of the +consequences. + .SH "OPTIONS" .TP -d -Include this switch to delete (unpublish) a branch. +Include this switch to delete (unpublish) a remote branch. -.TP --h -Display help message. +-f +Force a non-fast-forward update of the remote branch. .TP \fIBRANCH\fR