gitui-org / gitui-org/gitui

git-lfs support

Aperta
#2,812 6 commenti 3 reazioni 0 assegnatari Vedi su GitHub
feature-request
Lingua principale
Rust
Stelle
22.5k
Fork
773
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

Our current bug #2809 (our broken pre-push hook support) led me down the rabbit hole of "what else is required to properly support git-lfs in gitui.

We are looking at basically three things:
1. properly run pre-push hook (thats #2809)
2. hook into filter logic and run them on all checkout-like operations (smudge)
3. hook into filter logic and run them on all worktree->index operations (clean)

Now libgit2 exposes an API to hook into filters but git2-rs does not expose this right now ([open issue](https://github.com/rust-lang/git2-rs/issues/442)).

Since our end goal is to be libgit2 independent I call out whats needed to do this all using gitoxide:

1. we need to migrate all our git-checkout locations to gitoxide
2. migrate all worktree->index operations to gitoxide
3. ~~use gitoxide machinery to hook into filters~~ (turns out gitoxide will already invoke filters for us)
4. ~~forward filter logic via shellout (`git-lfs clean`, `git-lfs smudge` or `git-lfs filter-process`)~~
5. finally we support basic git-lfs
6. add support for more file locking relevant lfs features via hooks: `post-checkout`, `post-merge`, `post-commit`

This issue is more of an epic, I would love to see contributions to take on individual steps as separate PRs.

cc @Byron @cruessler correct me if I am wrong but from the gitoxide side all this is ready to be used or am I wrong?

Further reading: https://github.com/gitui-org/gitui/discussions/1089

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Tratta questo come un epic e scegli un passaggio definito in modo indipendente, iniziando dalle operazioni simili a checkout o worktree-to-index descritte nell’issue. Leggi i punti di integrazione pertinenti di gitoxide e verifica come vengono invocati i filtri. Un contributo completato dovrebbe fornire una migrazione o un hook separato verso il supporto di base per git-lfs, con il relativo comportamento validato rispetto all’obiettivo indicato.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
git, rust
Ambito
cli
Tipo di issue
Funzionalità
Difficoltà
5/5
Tempo stimato
Più di una settimana
Stato di attività
Ferma
Chiarezza
Abbastanza chiara
Idoneità per principianti
25/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.