{"thread":{"id":"40717","subject":"git gc/prune runs again and again","startedAt":"2015-11-03T12:44:20Z","lastAt":"2015-11-03T15:21:09Z","messageCount":3,"participants":["Andreas Krey","Duy Nguyen"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"272832","messageId":"20151103124420.GA10946@inner.h.apk.li","threadId":"40717","inReplyTo":null,"subject":"git gc/prune runs again and again","fromName":"Andreas Krey","fromEmail":"a.krey@gmx.de","sentAt":"2015-11-03T12:44:20Z","receivedAt":"2015-11-03T12:44:20Z","isPatch":false,"sender":{"key":"a.krey@gmx.de","avatar":"https://avatars.githubusercontent.com/u/37810?v=4"},"body":"Hi all,\n\nI have a bit of an annoying behaviour in git gc;\nthere is a repo I regularly do a fetch in, and\nthis kicks off a gc/prune every time. I remember\nthere being a heuristic with being that many files\nin .git/objects/17 as the gc trigger.\n\nWhich is unfortunate if the gc does not actually\nreduce the number of files there because they\naren't old enough => gc comes right back.\n\nWhat can I do there? (This git is a bit old, 2.2.2)\n\nAndreas\n\n\n-- \n\"Totally trivial. Famous last words.\"\nFrom: Linus Torvalds <torvalds@*.org>\nDate: Fri, 22 Jan 2010 07:29:21 -0800\n"},{"id":"272835","messageId":"CACsJy8DMyjaZ_jKz4B93e6gSgV7ensORqxD-WYOYL9=9SV5tLw@mail.gmail.com","threadId":"40717","inReplyTo":"20151103124420.GA10946@inner.h.apk.li","subject":"Re: git gc/prune runs again and again","fromName":"Duy Nguyen","fromEmail":"pclouds@gmail.com","sentAt":"2015-11-03T15:01:24Z","receivedAt":"2015-11-03T15:01:24Z","isPatch":false,"sender":{"key":"pclouds@gmail.com","avatar":"https://avatars.githubusercontent.com/u/720?v=4"},"body":"On Tue, Nov 3, 2015 at 1:44 PM, Andreas Krey <a.krey@gmx.de> wrote:\n> Hi all,\n>\n> I have a bit of an annoying behaviour in git gc;\n> there is a repo I regularly do a fetch in, and\n> this kicks off a gc/prune every time. I remember\n> there being a heuristic with being that many files\n> in .git/objects/17 as the gc trigger.\n>\n> Which is unfortunate if the gc does not actually\n> reduce the number of files there because they\n> aren't old enough => gc comes right back.\n>\n> What can I do there? (This git is a bit old, 2.2.2)\n\nRun \"git prune\". 2.2.2 hides this suggestion to run git-prune in this\ncase. The next git version will show it back.\n\n\n-- \nDuy\n"},{"id":"272836","messageId":"20151103152109.GA15036@inner.h.apk.li","threadId":"40717","inReplyTo":"CACsJy8DMyjaZ_jKz4B93e6gSgV7ensORqxD-WYOYL9=9SV5tLw@mail.gmail.com","subject":"Re: git gc/prune runs again and again","fromName":"Andreas Krey","fromEmail":"a.krey@gmx.de","sentAt":"2015-11-03T15:21:09Z","receivedAt":"2015-11-03T15:21:09Z","isPatch":false,"sender":{"key":"a.krey@gmx.de","avatar":"https://avatars.githubusercontent.com/u/37810?v=4"},"body":"On Tue, 03 Nov 2015 16:01:24 +0000, Duy Nguyen wrote:\n....\n> > I have a bit of an annoying behaviour in git gc;\n> > there is a repo I regularly do a fetch in, and\n> > this kicks off a gc/prune every time. I remember\n> > there being a heuristic with being that many files\n> > in .git/objects/17 as the gc trigger.\n\n(It might be a good idea to use a random slot here.)\n\n...\n> > What can I do there? (This git is a bit old, 2.2.2)\n> \n> Run \"git prune\". 2.2.2 hides this suggestion to run git-prune in this\n> case. The next git version will show it back.\n\nActually, there is a 'git prune --expire 2.weeks.ago --no-progress'\nrunning under the 'git gc --auto --quiet', and I don't want to drop\nthe expiry time lightly.\n\nAndreas\n\n-- \n\"Totally trivial. Famous last words.\"\nFrom: Linus Torvalds <torvalds@*.org>\nDate: Fri, 22 Jan 2010 07:29:21 -0800\n"}]}