{"thread":{"id":"17909","subject":"Shallow clones (git clone --depth) are broken?","startedAt":"2009-02-19T19:55:24Z","lastAt":"2009-02-20T02:49:49Z","messageCount":2,"participants":["Jim Ramsay","Jeff King"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"105540","messageId":"20090219145524.32ca3915@vrm378-02.vrm378.am.mot.com","threadId":"17909","inReplyTo":null,"subject":"Shallow clones (git clone --depth) are broken?","fromName":"Jim Ramsay","fromEmail":"i.am@jimramsay.com","sentAt":"2009-02-19T19:55:24Z","receivedAt":"2009-02-19T19:55:24Z","isPatch":false,"sender":{"key":"i.am@jimramsay.com","avatar":"https://gravatar.com/avatar/c5ae780989e8617fa3ad9c389bbbd3c57fa622ea3c27747ecf67a8891b15a35f?d=mp&s=160"},"body":"I've been trying to experiment with shallow clones, however I can't\nseem to actually create one.  Here's what I've tried, for example:\n\ngit clone --depth 1 git://git.fluxbox.org/fluxbox.git\n\nHowever, this gets me everything, and takes quite a while.  After it\ncompletes, running gitk shows me the entire history, and the size of\nthe .git directory is the same as a full clone I've done previously.\n\nI've tried this with both 1.6.0.2 and 1.6.1.3, to the same effect.\n\nCan anyone out there verify that this --depth option actually does\nanything?  Or could it potentially be the version of git on the\nserver?\n\nIf it's not just something odd I'm doing, I can take the time to\ntry to figure out in which version this *does* work, and when it\nstopped... Though others out there may be more equipped than I to chase\nthis down.\n\n-- \nJim Ramsay\n"},{"id":"105545","messageId":"20090220024948.GA22419@coredump.intra.peff.net","threadId":"17909","inReplyTo":"20090219145524.32ca3915@vrm378-02.vrm378.am.mot.com","subject":"Re: Shallow clones (git clone --depth) are broken?","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2009-02-20T02:49:49Z","receivedAt":"2009-02-20T02:49:49Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Thu, Feb 19, 2009 at 02:55:24PM -0500, Jim Ramsay wrote:\n\n> I've been trying to experiment with shallow clones, however I can't\n> seem to actually create one.  Here's what I've tried, for example:\n> \n> git clone --depth 1 git://git.fluxbox.org/fluxbox.git\n> \n> However, this gets me everything, and takes quite a while.  After it\n> completes, running gitk shows me the entire history, and the size of\n> the .git directory is the same as a full clone I've done previously.\n> \n> I've tried this with both 1.6.0.2 and 1.6.1.3, to the same effect.\n> \n> Can anyone out there verify that this --depth option actually does\n> anything?  Or could it potentially be the version of git on the\n> server?\n\nSorry, I can't reproduce (using 1.6.0.2):\n\n  $ git clone git://git.fluxbox.org/fluxbox.git full\n  Initialized empty Git repository in /home/peff/full/.git/\n  remote: Counting objects: 31521, done.\n  remote: Compressing objects: 100% (8013/8013), done.\n  remote: Total 31521 (delta 24321), reused 30542 (delta 23462)\n  Receiving objects: 100% (31521/31521), 8.08 MiB | 499 KiB/s, done.\n  Resolving deltas: 100% (24321/24321), done.\n  $ du -sh full/.git\n  9.2M    full/.git\n\n  $ git clone --depth 1 git://git.fluxbox.org/fluxbox.git shallow\n  Initialized empty Git repository in /home/peff/shallow/.git/\n  remote: Counting objects: 5402, done.\n  remote: Compressing objects: 100% (3310/3310), done.\n  remote: Total 5402 (delta 4148), reused 2969 (delta 2057)\n  Receiving objects: 100% (5402/5402), 3.07 MiB | 408 KiB/s, done.\n  Resolving deltas: 100% (4148/4148), done.\n  $ du -sh shallow/.git\n  3.5M    shallow/.git\n\nThere is some server support required for shallow clone; I didn't check,\nbut I assume that the client would degrade gracefully to a full clone.\nIn which case, is it possible that fluxbox.org upgraded since you\ntested? Can you try again?\n\n-Peff\n"}]}