Git Large File Storage

at what point should files be considered large ?

and what are the benefits to using LFS ?

2 answers

1 accepted

1 vote
Accepted answer

The definition of a large file is up to you, really. Long story short problem with large files on Git is that if they are modified throughout several commits, when devs checkout the code they'd be downloading all of the "large" files that are being tracked by Git. By using LFS, when you checkout a repo that has LFS enabled, devs will checkout a the big file on the latest commit but not all the previous ones unless they change to that commit. Only a small text file containing instructions on how to download the "large file" are stored in previous commits and hence prior versions are checked out on demand (i.e. if they checkout that commit/branch etc).

You can define whatever files you like to be a "large file" and then those will be handled that way bit Git when people clone that repo.

In-depth details: Atlassian Git LFS Tutorial

Thanks Thiago

Understanding how the files will be treated on the server makes all the difference. 

The size of the file makes little difference,  it is how it is used.

(edited after the fact, due to not being able to see what I was typing via a phone)

That's exactly right. You will have to tell Git LFS which files you want it to track (i.e. specific files, extensions like .psd or .bmp). It is all up to you. I am glad it helped. smile

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Nov 06, 2018 in Bitbucket

Upgrade Best Practices

Hello! My name is Mark Askew and I am a Premier Support Engineer for products Bitbucket Server/Data Center, Fisheye & Crucible. Today, I want to bring the discussion that Jennifer, Matt, and ...

212 views 3 7
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you