{"thread":{"id":"7620","subject":"One more shallow tree weirdness - tag not pulled?","startedAt":"2007-04-12T01:16:16Z","lastAt":"2007-04-12T03:37:59Z","messageCount":3,"participants":["Robin H. Johnson","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"39179","messageId":"20070412011616.GB18378@curie-int.orbis-terrarum.net","threadId":"7620","inReplyTo":null,"subject":"One more shallow tree weirdness - tag not pulled?","fromName":"Robin H. Johnson","fromEmail":"robbat2@gentoo.org","sentAt":"2007-04-12T01:16:16Z","receivedAt":"2007-04-12T01:16:16Z","isPatch":false,"sender":{"key":"robbat2@gentoo.org","avatar":"https://avatars.githubusercontent.com/u/373898?v=4"},"body":"One other bit of weirdness I ran into.  On a shallow clone that is extended to\nfull depth, there is a tag missing (that was in the non-shallow clone).\n\nTestcase\n> git clone git://git.kernel.org/pub/scm/git/git.git git-0\n> git clone --depth 1 git://git.kernel.org/pub/scm/git/git.git git-1\n> cd git-1 && git pull --depth 10000000\n\nNow the content of git-0 and git-1 should be functionally identical, but\nit's not.\n\nI created 'git-$N.list' with:\nfind git-$N ! -type d  | sort |egrep -v '\\.git/(objects/pack/|index$|logs/)' \\\n | tr '\\n' '\\0' | xargs -0 md5sum | sed 's,git-$N/,,g' >git-$N.list\n\n--- git-0.list\t2007-04-11 18:12:25.000000000 -0700\n+++ git-1.list\t2007-04-11 18:12:32.000000000 -0700\n@@ -28,7 +28,6 @@\n bc94cbd02df32d07b7fd230d7aba42e8  .git/refs/tags/gitgui-0.6.3\n 91521cca8d3f177e2f0cb4a586dac6be  .git/refs/tags/gitgui-0.6.4\n c56d1ac72d959f87ba0dd92721de36de  .git/refs/tags/gitgui-0.6.5\n-b9c7a4533d41dfedd0a0d23bbfb3fed8  .git/refs/tags/junio-gpg-pub\n 43ceb81bf4c131a8a882025a676aa22e  .git/refs/tags/v0.99\n 072e3055bf33ff1ba5aa4697f2b539fb  .git/refs/tags/v0.99.1\n 85916310d7d0a86818033ac95f32b234  .git/refs/tags/v0.99.2\n\n-- \nRobin Hugh Johnson\nGentoo Linux Developer & Council Member\nE-Mail     : robbat2@gentoo.org\nGnuPG FP   : 11AC BA4F 4778 E3F6 E4ED  F38E B27B 944E 3488 4E85\n"},{"id":"39180","messageId":"7vbqhuml6z.fsf@assigned-by-dhcp.cox.net","threadId":"7620","inReplyTo":"20070412011616.GB18378@curie-int.orbis-terrarum.net","subject":"Re: One more shallow tree weirdness - tag not pulled?","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2007-04-12T01:32:36Z","receivedAt":"2007-04-12T01:32:36Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Robin H. Johnson\" <robbat2@gentoo.org> writes:\n\n> One other bit of weirdness I ran into.  On a shallow clone that is extended to\n> full depth, there is a tag missing (that was in the non-shallow clone).\n>\n> Testcase\n>> git clone git://git.kernel.org/pub/scm/git/git.git git-0\n>> git clone --depth 1 git://git.kernel.org/pub/scm/git/git.git git-1\n>> cd git-1 && git pull --depth 10000000\n\nThis is easily explained, and I do not think it has anything to\ndo with shallow clones.\n\nThe initial clone gets all tags, regardless of reachability.\nSubsequent fetches however only _follows_ tags that point at\nsomething you have in the repository.  The blob that holds my\nGPG public key is not part of any commit, so you would not have\nthat object in your repository, and subsequent \"tag following\"\nwill not see it.\n\n\t$ git fetch --tags\n\nis always your friend.\n\n> I created 'git-$N.list' with:\n> find git-$N ! -type d  | sort |egrep -v '\\.git/(objects/pack/|index$|logs/)' \\\n>  | tr '\\n' '\\0' | xargs -0 md5sum | sed 's,git-$N/,,g' >git-$N.list\n\nI do not know what you wanted to do, but I suspect you\nreinvented a rather expensive\n\n\tgit ls-remote git-$N\n\nperhaps?\n\n>\n> --- git-0.list\t2007-04-11 18:12:25.000000000 -0700\n> +++ git-1.list\t2007-04-11 18:12:32.000000000 -0700\n> @@ -28,7 +28,6 @@\n>  bc94cbd02df32d07b7fd230d7aba42e8  .git/refs/tags/gitgui-0.6.3\n>  91521cca8d3f177e2f0cb4a586dac6be  .git/refs/tags/gitgui-0.6.4\n>  c56d1ac72d959f87ba0dd92721de36de  .git/refs/tags/gitgui-0.6.5\n> -b9c7a4533d41dfedd0a0d23bbfb3fed8  .git/refs/tags/junio-gpg-pub\n>  43ceb81bf4c131a8a882025a676aa22e  .git/refs/tags/v0.99\n>  072e3055bf33ff1ba5aa4697f2b539fb  .git/refs/tags/v0.99.1\n>  85916310d7d0a86818033ac95f32b234  .git/refs/tags/v0.99.2\n>\n> -- \n> Robin Hugh Johnson\n> Gentoo Linux Developer & Council Member\n> E-Mail     : robbat2@gentoo.org\n> GnuPG FP   : 11AC BA4F 4778 E3F6 E4ED  F38E B27B 944E 3488 4E85\n"},{"id":"39193","messageId":"20070412033759.GD18378@curie-int.orbis-terrarum.net","threadId":"7620","inReplyTo":"7vbqhuml6z.fsf@assigned-by-dhcp.cox.net","subject":"Re: One more shallow tree weirdness - tag not pulled?","fromName":"Robin H. Johnson","fromEmail":"robbat2@gentoo.org","sentAt":"2007-04-12T03:37:59Z","receivedAt":"2007-04-12T03:37:59Z","isPatch":false,"sender":{"key":"robbat2@gentoo.org","avatar":"https://avatars.githubusercontent.com/u/373898?v=4"},"body":"On Wed, Apr 11, 2007 at 06:32:36PM -0700, Junio C Hamano wrote:\n> The initial clone gets all tags, regardless of reachability.\n> Subsequent fetches however only _follows_ tags that point at\n> something you have in the repository.  The blob that holds my\n> GPG public key is not part of any commit, so you would not have\n> that object in your repository, and subsequent \"tag following\"\n> will not see it.\nAh, that explains it. I didn't dig into what the blob contain, just\nnoticed that it wasn't on the side that I was checking for extending.\n\n> > I created 'git-$N.list' with:\n> > find git-$N ! -type d  | sort |egrep -v '\\.git/(objects/pack/|index$|logs/)' \\\n> >  | tr '\\n' '\\0' | xargs -0 md5sum | sed 's,git-$N/,,g' >git-$N.list\n> \n> I do not know what you wanted to do, but I suspect you\n> reinvented a rather expensive\n> \tgit ls-remote git-$N\nNo, the purpose of this command was to check that the checkouts were\nfunctionally equivalent.\n\n-- \nRobin Hugh Johnson\nGentoo Linux Developer & Council Member\nE-Mail     : robbat2@gentoo.org\nGnuPG FP   : 11AC BA4F 4778 E3F6 E4ED  F38E B27B 944E 3488 4E85\n"}]}