]> asedeno.scripts.mit.edu Git - git.git/blobdiff - Documentation/git-branch.txt
Git 1.7.0.4
[git.git] / Documentation / git-branch.txt
index 0e836809c20c83b8798fc77fa373f17fbf5f1eb6..6b6c3da2d95ad2d5d94949034d5dd723f48d977a 100644 (file)
@@ -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>...
 
@@ -38,7 +38,7 @@ working tree to it; use "git checkout <newbranch>" to switch to the
 new branch.
 
 When a local branch is started off a remote branch, git sets up the
-branch so that 'git-pull' will appropriately merge from
+branch so that 'git pull' will appropriately merge from
 the remote branch. This behavior may be changed via the global
 `branch.autosetupmerge` configuration flag. That setting can be
 overridden by using the `--track` and `--no-track` options.
@@ -55,7 +55,7 @@ has a reflog then the reflog will also be deleted.
 
 Use -r together with -d to delete remote-tracking branches. Note, that it
 only makes sense to delete remote-tracking branches if they no longer exist
-in the remote repository or if 'git-fetch' was configured not to fetch
+in the remote repository or if 'git fetch' was configured not to fetch
 them again. See also the 'prune' subcommand of linkgit:git-remote[1] for a
 way to clean up all obsolete remote-tracking branches.
 
@@ -76,7 +76,7 @@ OPTIONS
 -f::
 --force::
        Reset <branchname> to <startpoint> if <branchname> exists
-       already. Without `-f` 'git-branch' refuses to change an existing branch.
+       already. Without `-f` 'git branch' refuses to change an existing branch.
 
 -m::
        Move/rename a branch and the corresponding reflog.
@@ -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.