3

(Windows 10 64-Bit) I'm using SourceTree and GitHub as a means of version control for my Unity project. I'm the only one in this project so there's one branch and that's all. The Unity project itself is around 2-3GB right now however my .git/objects/pack folder is over 270GB!

I have no idea when this came to be but it's ridiculous and I have not found any solution online to reduce this size. In fact every solution I try adds a GB to the folder. I've tried all that aggressive prune and repack stuff and am out of options.

Any help is appreciated, and please explain instructions in detail since I find a lot of answers online that require further research on my end to figure out how to even pull it off. I just need to reduce this size as much as possible without ruining my project; too many times I've tried to do a simple thing and have lost work in the process. I would even just delete all the files in the pack folder if I didn't feel like it would eternally delete all of my work.

Yan Dawid
  • 31
  • 1
  • 2
  • Have you been adding binaries to your repository? – ElpieKay Mar 02 '18 at 09:35
  • I don't know, how do I check? For future reference, just assume I'm a complete noob at this. Looking at my commits I don't see any .bin files in any of them. – Yan Dawid Mar 02 '18 at 09:36
  • Are there many binary files in your repo? Like images. – ElpieKay Mar 02 '18 at 09:37
  • 1
    Well I have pushed plenty of PNGs, they're the textures for my game. – Yan Dawid Mar 02 '18 at 09:39
  • 3
    Plenty of PNGs, old and new, take huge space. You can imagine Git stores every of them, even if in the latest revision many of them are not needed any more. Git is not good at handling with binaries. You could try `git-lfs` https://git-lfs.github.com/ – ElpieKay Mar 02 '18 at 09:42
  • 2
    Possible duplicate of [Remove large .pack file created by git](https://stackoverflow.com/questions/11050265/remove-large-pack-file-created-by-git) – hb20007 May 07 '19 at 12:42

0 Answers0