I have an issue with GIT LFS: my project got to a point in which I'm tracking 1.5GB of LFS data, much more than what I have (all tracked content without LFS would be 108MB). I started investigating this issue and it looks like since I started refactoring and moving my files around git lfs just duplicated the OIDs and tracked them several times.
I tried cleaning up the project using BFG by following this guide, when I run git lfs ls-files
it shows me the list of all tracked files with their updated OID (all looks fine). But when I push into my remote I get the following error:
Trying to push "Content/Static/Geometry/Meshes/1M_Cube.uasset" with OID f471a994148db424160e6589509afbe29b9205f5db07ab4c231811aefccff955.
Not found in D:\Projects\UnrealProjects\MasterOfShadows\.git\lfs\objects\f4\71.
Looking back at the history this 1M_Cube.uasset
had that OID in a previous commit but now since I re-tracked the files again has a different one.
Does anyone know how to clean LFS to stop tracking old OIDs?
Edit: This is what the logs shows about the tracking for that asset 8b84072d8a * Content/Static/Geometry/Meshes/1M_Cube.uasset
I also wanted to mention that when using BFG I ran these commands:
java -jar bfg.jar --delete-files .umap "D:\Projects\UnrealProjects\MasterOfShadows"
java -jar bfg.jar --delete-files .uasset "D:\Projects\UnrealProjects\MasterOfShadows"
git reflog expire --expire=now --all && git gc --prune=now --aggressive