Skip to content

Commit eb637e1

Browse files
namhyunggitster
authored andcommitted
git-remote.txt: fix wrong remote refspec
$GIT_DIR/remotes/<name>/<branch> should be $GIT_DIR/refs/remotes/<name>/<branch>. Signed-off-by: Namhyung Kim <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 4f83039 commit eb637e1

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

Documentation/git-remote.txt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,11 @@ the remote repository.
6060
+
6161
With `-t <branch>` option, instead of the default glob
6262
refspec for the remote to track all branches under
63-
`$GIT_DIR/remotes/<name>/`, a refspec to track only `<branch>`
63+
`$GIT_DIR/refs/remotes/<name>/`, a refspec to track only `<branch>`
6464
is created. You can give more than one `-t <branch>` to track
6565
multiple branches without grabbing all branches.
6666
+
67-
With `-m <master>` option, `$GIT_DIR/remotes/<name>/HEAD` is set
67+
With `-m <master>` option, `$GIT_DIR/refs/remotes/<name>/HEAD` is set
6868
up to point at remote's `<master>` branch. See also the set-head command.
6969
+
7070
When a fetch mirror is created with `\--mirror=fetch`, the refs will not
@@ -92,23 +92,23 @@ configuration settings for the remote are removed.
9292

9393
'set-head'::
9494

95-
Sets or deletes the default branch (`$GIT_DIR/remotes/<name>/HEAD`) for
95+
Sets or deletes the default branch (`$GIT_DIR/refs/remotes/<name>/HEAD`) for
9696
the named remote. Having a default branch for a remote is not required,
9797
but allows the name of the remote to be specified in lieu of a specific
9898
branch. For example, if the default branch for `origin` is set to
9999
`master`, then `origin` may be specified wherever you would normally
100100
specify `origin/master`.
101101
+
102-
With `-d`, `$GIT_DIR/remotes/<name>/HEAD` is deleted.
102+
With `-d`, `$GIT_DIR/refs/remotes/<name>/HEAD` is deleted.
103103
+
104104
With `-a`, the remote is queried to determine its `HEAD`, then
105-
`$GIT_DIR/remotes/<name>/HEAD` is set to the same branch. e.g., if the remote
105+
`$GIT_DIR/refs/remotes/<name>/HEAD` is set to the same branch. e.g., if the remote
106106
`HEAD` is pointed at `next`, "`git remote set-head origin -a`" will set
107107
`$GIT_DIR/refs/remotes/origin/HEAD` to `refs/remotes/origin/next`. This will
108108
only work if `refs/remotes/origin/next` already exists; if not it must be
109109
fetched first.
110110
+
111-
Use `<branch>` to set `$GIT_DIR/remotes/<name>/HEAD` explicitly. e.g., "git
111+
Use `<branch>` to set `$GIT_DIR/refs/remotes/<name>/HEAD` explicitly. e.g., "git
112112
remote set-head origin master" will set `$GIT_DIR/refs/remotes/origin/HEAD` to
113113
`refs/remotes/origin/master`. This will only work if
114114
`refs/remotes/origin/master` already exists; if not it must be fetched first.

0 commit comments

Comments
 (0)