Skip to contentSkip to conversation

[BUG} git-fetch - won't fetch wildcarded tags

DISCUSSION Mark Levedahl 3 participants 3 messages Jun 15, 2016

lore
Share & tools
lore
#0 lore raw

git fetch does not seem to handle refs/tags/* refspecs, at least no from bundles...

git>git bundle create /tmp/foo v1.5.2
<snip>
git>git ls-remote /tmp/foo
8b1e5575ab18757272e86c5ec7a10411bbaa3662 refs/tags/v1.5.2
git>git tag -d v1.5.2
Deleted tag v1.5.2.
git>git fetch /tmp/foo 'refs/tags/*:refs/tags/*'
* refusing to create funny ref 'tags/*' locally

Huh?

but...
git>git fetch /tmp/foo 'refs/tags/v1.5.2:refs/tags/v1.5.2'
* refs/tags/v1.5.2: storing tag 'v1.5.2' of /tmp/foo
tag: 8b1e557

What's going on? This is a severe limitation of the utility of bundles to transmit tagged versions.

Mark

#1 lore raw
Quoted 2 lines · Mark Levedahl

git fetch does not seem to handle refs/tags/* refspecs, at least no from bundles...

groan - Never mind
git fetch -t /tmp/foo

#2 lore raw
In reply to Mark Levedahl
Quoted 2 lines · Mark Levedahl

git>git fetch /tmp/foo 'refs/tags/*:refs/tags/*'
* refusing to create funny ref 'tags/*' locally

I think fetch's wildcard is effective only in the config file, and this is not just tags. It would be nice if you could say

	$ git fetch foo.bndl 'refs/*:refs/*'