Working on an all-Elixir implementation of git -- looking for co-contributors

Hi, I had the idea a few months ago that an all-Elixir implementation of git could be an interesting foundation for some future projects I’d like to build and also an interesting way to deeply learn the internals of git.

I’ve started this project as a port from jgit and have a fair amount of the core infrastructure ported. It’s far from ready for prime time, but I’m sharing this now in hopes of finding co-conspirators for this project.

If you are interested in contributing, the project – such as it is at the moment – is available as xgit on GitHub. Please reach out to me here or on GitHub.

Thanks!

-Eric

12 Likes

Thanks a lot :smiley:

This is according to the quote in the readme a pretty important implementation.

Do you know ocaml-git? Since I assume it is closer to your implementation as jgit is, so it could help you as an example.

1 Like

No, I was not familiar with ocaml-git. Good to know, though I’m far enough into it that it would be hard to switch gears now.

1 Like

There is also erlangit. Though, this has not been touched in almost ten years. You may already be further along than it was.

2 Likes

From the erlangit README:

It is currently slower than a slow-motion replay of a cold-weather molasses drip-race judged by sloths who just took Nyquil. Slowly.

:rofl:

10 Likes

Nice, but one suggestion:

Split that library and at first implement only libgit2 functionalities instead of whole CLI UI. It is more important to be able to work with the repo itself programmatically rather than using particular CLI commands (and that will be much easier to work that way).

11 Likes

Yes, definitely this!

3 Likes

Split that library and at first implement only libgit2 functionalities instead of whole CLI UI.

This was essentially my goal, but apparently not stated clearly enough.

FWIW I’ve spoken privately with one of the lead authors of jgit and had a similar response: Given my stated goal of creating something that can be used for a git server and not a local workstation git client, time spent working on working tree operations (and likewise, any concurrent interop on disk with command-line git or jgit) is essentially wasted.

As I have time, I’ll be redirecting the project in that direction.

Thank you all for your feedback.

5 Likes

Totally not what you asked for, but can I see if you are aware (or might like to work with):

https://github.com/almightycouch/gitgud

1 Like

I posted a couple months ago about my effort to build an all-Elixir implementation of git. Based on some feedback and some further experiences in the porting effort, I’ve shifted gears to fully focus on building a server-native, Elixir-native git implementation.

More on the new effort and how I got to that point: https://xgit.io/burning-down-the-house/

4 Likes

More on Xgit’s progress: Xgit Reflog: All the World’s a (git) Stage.

Looking for advice on a couple of Erlang/OTP design issues: One is Xgit specific (how to manage a potentially large volume of data across process boundaries). Another is more tied to zlib, so I’ll post that in a separate thread.

Also: If you’ve followed this project on GitHub, your watches and follows appear to have followed the archiving of the previous jgit-based project. If you are still interested, please re-follow the current Xgit project.

3 Likes