aboutsummaryrefslogtreecommitdiff
path: root/builtin-clone.c
diff options
context:
space:
mode:
authorJohannes Schindelin <Johannes.Schindelin@gmx.de>2008-08-08 04:29:35 +0200
committerJunio C Hamano <gitster@pobox.com>2008-08-07 21:25:27 -0700
commit468386a956c09ff59dd2b8fd681e162b2e167392 (patch)
treed497047fbdb7893c5693574792ea2c242ed7e367 /builtin-clone.c
parent1fdf6ee6f81b31b299a8039832f45290faa4583a (diff)
downloadgit-468386a956c09ff59dd2b8fd681e162b2e167392.tar.gz
git-468386a956c09ff59dd2b8fd681e162b2e167392.tar.xz
clone --mirror: avoid storing repeated tags
With --mirror, clone asks for refs/* already, so it does not need to ask for ref/tags/*, too. Noticed by Cesar Eduardo Barros. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin-clone.c')
-rw-r--r--builtin-clone.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/builtin-clone.c b/builtin-clone.c
index 8612d59dd..c0e308643 100644
--- a/builtin-clone.c
+++ b/builtin-clone.c
@@ -330,7 +330,8 @@ static struct ref *write_remote_refs(const struct ref *refs,
struct ref *r;
get_fetch_map(refs, refspec, &tail, 0);
- get_fetch_map(refs, tag_refspec, &tail, 0);
+ if (!option_mirror)
+ get_fetch_map(refs, tag_refspec, &tail, 0);
for (r = local_refs; r; r = r->next)
add_extra_ref(r->peer_ref->name, r->old_sha1, 0);