author | Junio C Hamano <gitster@pobox.com> | |
Sat, 9 Jun 2007 08:37:14 +0000 (01:37 -0700) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Sat, 9 Jun 2007 18:53:01 +0000 (11:53 -0700) | ||
commit | 1ed10b886bc69c129c06772ee4310c00e001657f | |
tree | f19105cd3c933ad98f9143163b781393ffcb8fdf | tree | snapshot |
parent | 6125796f7d6e8b84431f92c13d7e79bd30f94f53 | commit | diff |
remote.c: "git-push frotz" should update what matches at the source.
Earlier, when the local repository has a branch "frotz" and the
remote repository has a tag "frotz" (but not branch "frotz"),
"git-push frotz" mistakenly updated the tag at the remote side.
This was because the partial refname matching code was applied
independently on both source and destination side.
With this fix, when a colon-less refspec is given to git-push,
we first match it with the refs in the source repository, and
update the matching ref in the destination repository.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Earlier, when the local repository has a branch "frotz" and the
remote repository has a tag "frotz" (but not branch "frotz"),
"git-push frotz" mistakenly updated the tag at the remote side.
This was because the partial refname matching code was applied
independently on both source and destination side.
With this fix, when a colon-less refspec is given to git-push,
we first match it with the refs in the source repository, and
update the matching ref in the destination repository.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
remote.c | diff | blob | history | |
t/t5516-fetch-push.sh | diff | blob | history |