3 ms·
Git can be very performant if you use a good interface to it. Unfortunately, the CLI interfaces are slow, and e.g. libgit2 is a bit awkward to use. However, the
by CyberShadow 5y ago
Git can be very performant if you use a good interface to it. Unfortunately, the CLI interfaces are slow, and e.g. libgit2 is a bit awkward to use. However, there is the object reader and writer interface, which allows reading and writing raw Git objects to its database - with it, you can build some nice high-performance tools.
For example, here is a program which, given a file's SHA1 and path, finds the last commit to have that file version at that path:
https://github.com/cybershadow/misc/blob/master/git-find-file-with-sha1.d https://github.com/cybershadow/misc/blob/master/git-find-fil...