by raffraffraff · 3y ago · 0 comments
Edit: I wondered about using a separate Blockchain to maintain consensus on the "central" representation of the repo that we get from a "git server". This answer is useful, I think I'll digest it and ponder some more...
https://stackoverflow.com/a/59509859
Edit2: I also wondered if anyone implemented git server as an extremely thin layer on top of s3, but the only project I found was abandoned many years ago.
I was always a bit disappointed that it didn't catch on, but I realize it would require a UI and probably buy-in from companies like Github and Gitlab, whose whole business is based around the lack of these features in git, so it was DoA, unfortunately.
Update: looks like that link above was a separate attempt from [1] and [2]
There's nothing special about a "git server": you can clone/push/pull/etc. from any checkout you like (apart from shallow clones, which may not have the requested commits). You can do this using local file paths, or over SSH, or over HTTP, etc. For example, here's an old blog post describing my git setup (pushing commits between folders on my laptop, and syncing those to multiple mirrors (a self-hosted static file server and GitHub) when online): http://www.chriswarbo.net/blog/2015-06-06-more_git.html
You might declare that some particular clone is the central repo for some project, but nobody has to care what you say: everyone's free to push/pull from each other, or send patches over email, regardless of what you've written on some blockchain or website. That's an advantage of git!
Edit: If you want a verifiable mechanism to know what X considers to be the canonical version of Y, you can use "whichever commit of Y that's signed by X has the highest timestamp". That may work better with more anonymous p2p transports like https://github.com/dhappy/git-remote-ipfs https://scuttlebot.io/apis/community/git-ssb.html