Skip to content

git-lfs support #2812

@extrawurst

Description

@extrawurst

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 Pushing throws pre-push hook error on repository with LFS. #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).

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: #1089

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions