diff options
author | Ilari Liusvaara <ilari.liusvaara@elisanet.fi> | 2010-01-18 23:44:11 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2010-01-19 04:09:32 +0300 |
commit | 4fc500667636c4ada592a40c4d11ce0560c43c0d (patch) | |
tree | 78c07862f09c2b89339a53a287a4f5540dc73a4c /Documentation | |
parent | ff6d26a0e1d8fad775010fa3b689c0c027da8bb0 (diff) |
Add branch --set-upstream
Add --set-upstream option to branch that works like --track, except that
when branch exists already, its upstream info is changed without changing
the ref value.
Based-on-patch-from: Matthieu Moy <Matthieu.Moy@imag.fr>
Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
Signed-off-by: Ilari Liusvaara <ilari.liusvaara@elisanet.fi>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/git-branch.txt | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/Documentation/git-branch.txt b/Documentation/git-branch.txt index 0e836809c2..a0d6a7a649 100644 --- a/Documentation/git-branch.txt +++ b/Documentation/git-branch.txt @@ -11,7 +11,7 @@ SYNOPSIS 'git branch' [--color | --no-color] [-r | -a] [-v [--abbrev=<length> | --no-abbrev]] [(--merged | --no-merged | --contains) [<commit>]] -'git branch' [--track | --no-track] [-l] [-f] <branchname> [<start-point>] +'git branch' [--set-upstream | --track | --no-track] [-l] [-f] <branchname> [<start-point>] 'git branch' (-m | -M) [<oldbranch>] <newbranch> 'git branch' (-d | -D) [-r] <branchname>... @@ -129,6 +129,12 @@ start-point is either a local or remote branch. Do not set up "upstream" configuration, even if the branch.autosetupmerge configuration variable is true. +--set-upstream:: + If specified branch does not exist yet or if '--force' has been + given, acts exactly like '--track'. Otherwise sets up configuration + like '--track' would when creating the branch, except that where + branch points to is not changed. + --contains <commit>:: Only list branches which contain the specified commit. |