{"thread":{"id":"21786","subject":"does clone --depth work?","startedAt":"2009-11-29T16:03:52Z","lastAt":"2009-11-30T08:18:00Z","messageCount":3,"participants":["Dan Carpenter","Björn Steinbrink"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"128687","messageId":"20091129160352.GO10640@bicker","threadId":"21786","inReplyTo":null,"subject":"does clone --depth work?","fromName":"Dan Carpenter","fromEmail":"error27@gmail.com","sentAt":"2009-11-29T16:03:52Z","receivedAt":"2009-11-29T16:03:52Z","isPatch":false,"sender":{"key":"error27@gmail.com","avatar":null},"body":"I do: `git clone --depth 0 ./repo1/ repo2`  I expected that \n\"git log\" in repo2 wouldn't show any revisions, but it does.\n\nI'm using 1.6.5.3.171.ge36e.dirty (small unrelated modification).\n\nAm I doing something incorrectly?\n\nregards,\ndan carpenter\n"},{"id":"128689","messageId":"20091129163242.GA7921@atjola.homenet","threadId":"21786","inReplyTo":"20091129160352.GO10640@bicker","subject":"Re: does clone --depth work?","fromName":"Björn Steinbrink","fromEmail":"b.steinbrink@gmx.de","sentAt":"2009-11-29T16:32:42Z","receivedAt":"2009-11-29T16:32:42Z","isPatch":false,"sender":{"key":"b.steinbrink@gmx.de","avatar":"https://avatars.githubusercontent.com/u/230962?v=4"},"body":"On 2009.11.29 18:03:52 +0200, Dan Carpenter wrote:\n> I do: `git clone --depth 0 ./repo1/ repo2`  I expected that \n> \"git log\" in repo2 wouldn't show any revisions, but it does.\n> \n> I'm using 1.6.5.3.171.ge36e.dirty (small unrelated modification).\n> \n> Am I doing something incorrectly?\n\nTwo problems:\na) IIRC depth = 0 is like not specifying depth at all\nb) When using plain paths, clone optimizes the process by just doing a\ncopy, that doesn't apply the depth setting at all\n\ngit clone --depth=1 file://$PWD/repo1 repo2\n\nThat should work. Of course you still got some commits, so \"git log\"\nwill show them. You just don't get all of them, but only to a certain\ndepth.\n\nBjörn\n"},{"id":"128748","messageId":"20091130081800.GR10640@bicker","threadId":"21786","inReplyTo":"20091129163242.GA7921@atjola.homenet","subject":"Re: does clone --depth work?","fromName":"Dan Carpenter","fromEmail":"error27@gmail.com","sentAt":"2009-11-30T08:18:00Z","receivedAt":"2009-11-30T08:18:00Z","isPatch":false,"sender":{"key":"error27@gmail.com","avatar":null},"body":"On Sun, Nov 29, 2009 at 05:32:42PM +0100, Björn Steinbrink wrote:\n> On 2009.11.29 18:03:52 +0200, Dan Carpenter wrote:\n> > I do: `git clone --depth 0 ./repo1/ repo2`  I expected that \n> > \"git log\" in repo2 wouldn't show any revisions, but it does.\n> > \n> > I'm using 1.6.5.3.171.ge36e.dirty (small unrelated modification).\n> > \n> > Am I doing something incorrectly?\n> \n> Two problems:\n> a) IIRC depth = 0 is like not specifying depth at all\n> b) When using plain paths, clone optimizes the process by just doing a\n> copy, that doesn't apply the depth setting at all\n> \n> git clone --depth=1 file://$PWD/repo1 repo2\n> \n\nAwesome.  That does work.\n\nthanks,\ndan\n\n> That should work. Of course you still got some commits, so \"git log\"\n> will show them. You just don't get all of them, but only to a certain\n> depth.\n> \n> Björn\n"}]}