Hacker News new | ask | show | jobs
by Conlectus 2105 days ago
Looks neat! This reminds me heavily of the excellent Building Git by James Coglan[1].

From a cursory glance though, it doesn't seem to support reading packfiles. This was the big thing that prevented me from using a fully custom Git implementation when I wrote my git churn calculator[2]. For larger repositories, it seems that almost all files are stored in packfiles, rather than the conceptually simpler "loose" format.

For me, the most valuable resource was reading the Git / libgit2 source and reference documentation.

[1] https://shop.jcoglan.com/building-git/

[2] https://github.com/samdoiron/butter

2 comments

Thanks! Note that ugit isn't supposed to be a custom compatible Git implementation, but rather a simplified Git-like implementation for teaching Git concepts. So even if ugit supported packfiles, it still won't be able to read a real Git repo.
Seconding the recommendation for "Building Git", one of the most lucid and edifying books I've read in recent years.