News for hackers. Stuff that matters.
Re:Show HN: ugit – Learn Git Internals by Building Git in Py... by Conlectus on Friday September 18, 2020 @02:36PM (#24520351)
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

Re:Show HN: ugit – Learn Git Internals by Building Git in Py... by nikital on Friday September 18, 2020 @02:57PM (#24520597)
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.
Re:Show HN: ugit – Learn Git Internals by Building Git in Py... by microtherion on Friday September 18, 2020 @03:14PM (#24520790)
Seconding the recommendation for "Building Git", one of the most lucid and edifying books I've read in recent years.