Code

deprecate the new loose object header format
[git.git] / Documentation / git-remote.txt
index 266faade31ae646a419616fc0fce9d676f112d9d..3dde7134a5cedc6d58a934e1dd61db26d5e459ae 100644 (file)
@@ -10,7 +10,7 @@ SYNOPSIS
 --------
 [verse]
 'git-remote'
-'git-remote' add <name> <url>
+'git-remote' add [-t <branch>] [-m <branch>] [-f] <name> <url>
 'git-remote' show <name>
 'git-remote' prune <name>
 'git-remote' update [group]
@@ -40,7 +40,7 @@ With `-t <branch>` option, instead of the default glob
 refspec for the remote to track all branches under
 `$GIT_DIR/remotes/<name>/`, a refspec to track only `<branch>`
 is created.  You can give more than one `-t <branch>` to track
-multiple branche without grabbing all branches.
+multiple branches without grabbing all branches.
 +
 With `-m <master>` option, `$GIT_DIR/remotes/<name>/HEAD` is set
 up to point at remote's `<master>` branch instead of whatever
@@ -77,8 +77,8 @@ gitlink:git-config[1]).
 Examples
 --------
 
-Add a new remote, fetch, and check out a branch from it:
-
+* Add a new remote, fetch, and check out a branch from it
++
 ------------
 $ git remote
 origin
@@ -98,6 +98,17 @@ $ git checkout -b nfs linux-nfs/master
 ...
 ------------
 
+* Imitate 'git clone' but track only selected branches
++
+------------
+$ mkdir project.git
+$ cd project.git
+$ git init
+$ git remote add -f -t master -m master origin git://example.com/git.git/
+$ git merge origin
+------------
+
+
 See Also
 --------
 gitlink:git-fetch[1]