Git LFS Usage on GitLab Repositories#

In newer GitLab versions LFS Storage needs to be specifically enabled for projects; you can achieve this in the settings of your project [1].

Unless you do this you might receive errors after you tell git lfs to track certain extensions while pushing refs:

1$ git push
2[master 108bec5] (use "git restore --staged <file>..." to unstage) new file:   .gitattributes
3 1 file changed, 42 insertions(+)
4 create mode 100644 site/.gitattributes
5Remote "origin" does not support the LFS locking API. Consider disabling it with:
6  $ git config lfs.https://glme/jdsalaro/jdsalaro.gitlab.io.git/info/lfs.locksverify false
7batch request: unexpected end of JSON inputB/s                                                                                                                                                              
8Uploading LFS objects:   0% (0/35), 0 B | 0 B/s, done.
9error: failed to push some refs to [...]

Addendum#

Once youโ€™re done reading this article, you can continue by having a look at the related content Iโ€™ve linked below.