Re: Why Git LFS is not a built-in feature

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2020-11-13 at 09:45:52, Alireza wrote:
> Currently, having to set up git-lfs in each client and checking server
> compatibility is a huge barrier for using it in the first place,
> whilst it is generally a good practice to store large files in lfs.
> 
> As a consequence a lot of repos are not using it when they should.
> 
> Is there any reason that we don't have built-in support for such an
> important feature?

There are a couple reasons that it's not a built-in feature:

* First, there are several options in this space.  Git LFS is one,
  git-annex is another, and some people prefer to store large objects in
  the repository and use partial clone.  Git, as a project, tries to be
  flexible and meet the needs of various kinds of users without
  privileging one or another external tool.
* Git LFS is a complicated piece of software and it's currently written
  in Go, which is different from most of Git.  Re-implementing it in C
  would be burdensome, and there's little interest in maintaining Go
  software in the Git project.
* Git LFS uses a different protocol from Git, requiring additional
  configuration and a separate server-side component.
* The smudge and clean filter approach has some limitations, among them
  that users who don't have the external filter installed can commit
  uncleaned objects that then result in the working tree consistently
  being modified, even after git reset --hard.

It's my hope that the built-in support for partial clone will mature
enough to the point where that's a clear win and the need for external
tools isn't as great, since I think that will ultimately provide a
better experience for users.  Some people are already using it.  So in
some sense, we do have this as a built-in feature, maybe just not the
one you were expecting.

Additionally, in many cases, projects can avoid the need for storing
large files at all by using repository best practices, like not storing
build products or binary dependencies in the repository and instead
using an artifact server or a standard packaging system.  If possible,
that will almost always provide a better experience than any solution
for storing large files in the repository.

Finally, if you do want to use an external tool like Git LFS, it's
reasonably straightforward to specify a script to install and configure
the required dependencies for your project on each system so that
everything just works.  One popular location for this kind of path is
script/bootstrap.
-- 
brian m. carlson (he/him or they/them)
Houston, Texas, US

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux