Date: Fri, 8 Jan 2021 10:47:34 +0000 From: Pete French <petefrench@ingresso.co.uk> To: freebsd-stable@freebsd.org Subject: Re: How to handle the pack files now we have switched to git? Message-ID: <2850cb71-6471-d672-25bc-eafb16c75954@ingresso.co.uk> In-Reply-To: <X/Xbq/fTKHMXUX82@acme.spoerlein.net> References: <22d067ae-c204-0dc5-4195-2d1c07f35560@ingresso.co.uk> <X/Xbq/fTKHMXUX82@acme.spoerlein.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On 06/01/2021 15:47, Ulrich Spörlein wrote: > That's not entirely correct. The packfile will only be rewritten if > a) enough other stuff has accumulated > b) you force a repack. > > You are fighting against git's GC mechanism a bit here, but you can > still make it work. On your source of truth host, do the following: > > 1. git gc --aggressive > 2. look at .git/objects/pack, there should be a single big pack > 3. touch .git/objects/pack/pack-<whateverhash>.keep (or was it > .pack.keep?) > 4. rsync --del to all other hosts > > Now future git gc runs will not delete that big pack, you'll only get > churn in the new, much smaller, packs. I missed seeing this until now, sorry, but thankyou! This is excellent, and looks like a much better solution - or at least one which lets me know 100% that I have percisely the same files on each machine. I will gve this a try next time I need to do an update. thanks, -pete.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?2850cb71-6471-d672-25bc-eafb16c75954>