In-reply-to » I now have an archive of over 1,000,000 Git commits across 154 repositories with my archival script.

@prologic@twtxt.net Git itself is a distributed network of mirrors. It’s impossible to truly kill a Git repository as long as someone still has a clone of it on their computer.

However, simple clones are inefficient on disk space and a simple git fetch will happily obliterate its history if the remote says so.

My goals are as follows.

  1. Create high quality archives of a large number of repositories and keep them up to date.
  2. Make them resilient against attacks from the inside, including (but not limited to) force-pushing an empty history and maliciously deleting branches on the remote.
  3. Minimize storage and bandwidth usage, including (but not limited to) running git gc --aggressive when cloning and not fetching unnecessary commits, e.g. Dependabot and pull requests.

⤋ Read More