Skip to content

Add support for Git LFS repositories

Ben Brown requested to merge (removed):benbrown/lfs into master

This series enables support for fetching git-lfs managed binaries.

Git LFS requires a remote server[1] in order to fetch, and so will not work as is with the way ybd caches gits. As such, lfs binaries are fetched on checkout, from the upstream repository. Whether or not a fetch of lfs binaries is required is determined by parsing the .gitattributes at the relevant revision for each checkout. Given a set of definitions without any LFS managed repositories, git-lfs installation is not required.

In order to support caching of such binaries, we would either require support for fetching from a local path in git-lfs, or we have ybd setup a simple server in order to serve gits to itself. The latter case would require implementation of the lfs server api, we could make use of pre-existing implementations[2].

Thoughts and feedback appreciated.

[1] https://github.com/git-lfs/git-lfs/issues/1338
[2] https://github.com/mgax/lfs

Merge request reports