author | Junio C Hamano <junkio@cox.net> | |
Sat, 16 Dec 2006 09:14:39 +0000 (01:14 -0800) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Sat, 16 Dec 2006 21:01:41 +0000 (13:01 -0800) | ||
commit | 61dde8f91672ab362f3cfd3af8d6d09d448d4ffe | |
tree | 7abc0686174d503cad6820e68044d90e87121d4e | tree | snapshot |
parent | b1bfcae438adb485bb66e2f59396373809e346e6 | commit | diff |
git-clone: use wildcard specification for tracking branches
This stops enumerating the set of branches found on the remote
side when a clone was made in the configuration file. Instead,
a single entry that maps each remote branch to the local
tracking branch for the remote under the same name is created.
Doing it this way not only shortens the configuration file, but
automatically adjusts to a new branch added on the remote side
after the clone is made.
Unfortunately this cannot be done for the traditional layout,
where we always need to special case the 'master' to 'origin'
mapping within the local branch namespace. But that is Ok; it
will be going away before v1.5.0.
We could also lose the "primary branch" mapping at the
beginning, but that has to wait until we implement the "forbid
'git pull' when we do not have branch.$current.merge for the
current branch" policy we earlier discussed. That should also
be in v1.5.0
Signed-off-by: Junio C Hamano <junkio@cox.net>
This stops enumerating the set of branches found on the remote
side when a clone was made in the configuration file. Instead,
a single entry that maps each remote branch to the local
tracking branch for the remote under the same name is created.
Doing it this way not only shortens the configuration file, but
automatically adjusts to a new branch added on the remote side
after the clone is made.
Unfortunately this cannot be done for the traditional layout,
where we always need to special case the 'master' to 'origin'
mapping within the local branch namespace. But that is Ok; it
will be going away before v1.5.0.
We could also lose the "primary branch" mapping at the
beginning, but that has to wait until we implement the "forbid
'git pull' when we do not have branch.$current.merge for the
current branch" policy we earlier discussed. That should also
be in v1.5.0
Signed-off-by: Junio C Hamano <junkio@cox.net>
git-clone.sh | diff | blob | history |