Commit 570c4928 authored by Douwe Maan's avatar Douwe Maan

Merge branch 'fj-applying-lfs-options-to-newer-git-version' into 'master'

Add git filter flag only if it is supported

See merge request gitlab-org/gitlab-ce!19529
parents e114c6fc ea2bd9cb
......@@ -39,7 +39,11 @@ module Gitlab
end
def git_all_pointers
params = { options: ["--filter=blob:limit=#{Gitlab::Git::Blob::LFS_POINTER_MAX_SIZE}"], require_path: true }
params = { require_path: true }
if Gitlab::Git.version >= Gitlab::VersionInfo.parse('2.16.0')
params[:options] = ["--filter=blob:limit=#{Gitlab::Git::Blob::LFS_POINTER_MAX_SIZE}"]
end
rev_list.all_objects(params) do |object_ids|
Gitlab::Git::Blob.batch_lfs_pointers(@repository, object_ids)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment