{"thread":{"id":"59494","subject":"Removing old objects from partial clone","startedAt":"2023-03-28T23:28:43Z","lastAt":"2023-03-29T08:52:46Z","messageCount":2,"participants":["uzytkownik2@gmail.com","Christian Couder"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"474384","messageId":"83c29b890e7c31e0f174b8a5da22c5b20ce647da.camel@gmail.com","threadId":"59494","inReplyTo":null,"subject":"Removing old objects from partial clone","fromName":"","fromEmail":"uzytkownik2@gmail.com","sentAt":"2023-03-28T23:28:35Z","receivedAt":"2023-03-28T23:28:43Z","isPatch":false,"sender":{"key":"uzytkownik2@gmail.com","avatar":null},"body":"Hi,\n\nI'd like to periodically remove objects which:\n\n - Are not reachable from newest N commits from any branch\n - Can be fetched from server if needed\n\nUnfortunatly I work on large repo and git gc doesn't work as all\nobjects are still technically reachable.\n\n\n"},{"id":"474398","messageId":"CAP8UFD1SwJeAF_n=yTjrDFZg10Y7oBNiQORKSkH=USHQLVfo5g@mail.gmail.com","threadId":"59494","inReplyTo":"83c29b890e7c31e0f174b8a5da22c5b20ce647da.camel@gmail.com","subject":"Re: Removing old objects from partial clone","fromName":"Christian Couder","fromEmail":"christian.couder@gmail.com","sentAt":"2023-03-29T08:51:38Z","receivedAt":"2023-03-29T08:52:46Z","isPatch":false,"sender":{"key":"christian.couder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/208954?v=4"},"body":"Hi,\n\nOn Wed, Mar 29, 2023 at 2:13 AM <uzytkownik2@gmail.com> wrote:\n>\n> Hi,\n>\n> I'd like to periodically remove objects which:\n>\n>  - Are not reachable from newest N commits from any branch\n>  - Can be fetched from server if needed\n>\n> Unfortunatly I work on large repo and git gc doesn't work as all\n> objects are still technically reachable.\n\nJohn Cai and I have been working on a new `--filter` option for `git\nrepack` that might help you but is dangerous to use (as it could\nremove objects that haven't be pushed which could corrupt the repo).\n\nWe haven't been able to get it accepted but you may still find the\ndiscussions and code interesting.\n\nSee https://lore.kernel.org/git/20221221040446.2860985-1-christian.couder@gmail.com/\n"}]}