Reputation: 4097
I have been given an old repository with LFS but some of the (probably older) files are missing so I cannot push:
git push -u origin
Locking support detected on remote "origin". Consider enabling it with:
$ git config lfs.https://gitlab.com/gitlabaccount/repo.git/info/lfs.locksverify true
Unable to find source for object 43cb9e6d1d15bb8d31af911aa69a15a67174c5 (try running git lfs fetch --all)
Uploading LFS objects: 87% (600/691), 546 MB | 0 B/s, done
error: failed to push some refs to '[email protected]:gitlabaccount/repo.git'
My colleague allegedly ran git lfs fetch --all
and it did not fix the problem.
I would really just like a copy of the latest, all history, and a build that works now. I'm not really worried about the older files and my preference would be to complete the push and lose a few missing lfs files but the lfs error will not let me.
Gitlab would allow me to disable lfs on the project but I dont know what will happen to the size/limits if I do this. Not sure what would be the proper procedure to enable then disable it on the server or the client. Alternatively, is there a "ignore missing files" option for the push?
Upvotes: 9
Views: 8454
Reputation: 101
git config lfs.allowincompletepush true
works for me. It ignores broken lfs objects.
Upvotes: 1
Reputation: 1674
You can ignore it using below, it will ignore pre-push hook of git lfs
git push --no-verify
Upvotes: 8