chaoss / chaoss/CollectOSS

facade: use libgit2 for git operations to improve performance and security

Open
#258 4 comments 0 reactions 0 assignees View on GitHub
discussion task:facade tech debt
Dominant language
Python
Stars
13
Forks
17
Avg merge
6h 59m
Merged PRs (30d)
1

Description

> [!NOTE]
> Migrated from [augurlabs/augur#3787](https://github.com/augurlabs/augur/issues/3787)
> Originally opened by `@MoralCode` on 2026-03-20

---

Libgit2 ([website](https://www.libgit2.org/), [repo](https://github.com/libgit2/libgit2)) is a cross platform C library implementing the git plumbing. It is designed for use as a library within complex applications, unlike the git CLI which is designed as a CLI. ([source](https://stackoverflow.com/a/22097293))

https://www.pygit2.org/ is the python version of this.

I learned about libgit2 through a conversation in a nerdy group chat of mine where there was a large 80ms -> 0.5ms speedup for one minimal usecase (render times for displaying git repo status in your shell prompt). While this may not be applicable to Augur directly, I wonder if we could eliminate a lot of shell calls, parsing bugs, and extra layers in the process when facade collects a git repo by using git more directly via a library that directly interfaces with git's plumbing, rather than calling an external program to do it.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.