DEV Community

Akira Game
Akira Game

Posted on

1

Deal with large file in Unity Project

Introduction

I have been using Github since I became an engineer, but I had a problem with Github when I used Unity at first time. That is a large file in Unity project.
This post will show what is problem and how deal with it.

Problem

Restriction

There is the default restriction of github that player cannot upload move than 100.00MB file. However, Unity projects sometimes have move than 100.00MB like .dylib file. The result is to fail to push file.

Solution

Solution1 ~~ .gitignore ~~

By utilizing the .gitignore file, you can manage unnecessary files without uploading them to GitHub. This can also help you avoid uploading large files.

Solution2 ~~ LFS ~~

If there are still large files, you will need to use Git Large File Storage that offered by Github. It can make users to upload move than 100.00MB.

How to use LFS

1.Install LFS

In case Mac

brew install git-lfs
Enter fullscreen mode Exit fullscreen mode

2.Intall local repository

git lfs install
Enter fullscreen mode Exit fullscreen mode

3.Track Large File

git lfs track "*.dylib"
Enter fullscreen mode Exit fullscreen mode

You will be able to upload the tracked file, even it is a large.

AWS Security LIVE!

Join us for AWS Security LIVE!

Discover the future of cloud security. Tune in live for trends, tips, and solutions from AWS and AWS Partners.

Learn More

Top comments (0)

AWS Security LIVE!

Join us for AWS Security LIVE!

Discover the future of cloud security. Tune in live for trends, tips, and solutions from AWS and AWS Partners.

Learn More

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay