I’m working on a Unity-Project and just created a new branch. But I forgot to exclude the generated lightmaps (huge files). So git says:
<File> exceeds GitHub's file size limit of 100.00 MB
Alright, no problem, I didn’t need them anyway right now, so I deleted the folder and added exclusion to my .gitignore (LightingData.asset)
So lets push again:
remote: error: File Assets/_Scenes/Nobi/T-2/LightingData.asset is 173.19 MB; this exceeds GitHub's file size limit of 100.00 MB
What? The file doesn’t even exist anymore. So I googled, and tried. For hours.
I tried everything the community suggested:
git rm Assets/_Scenes/Nobi/T-2/LightingData.asset git rm --cached Assets/_Scenes/Nobi/T-2/LightingData.asset git filter-branch --tree-filter 'rm -rf Assets/_Scenes/Nobi/T-2/LightingData.asset' git filter-branch -f --index-filter 'git rm --cached --ignore-unmatch Assets/_Scenes/Nobi/T-2/LightingData.asset'
I even did git reset --soft Head~1 and git reset --hard HEAD , readded and comitted and whatnot.
git rm -r --cached .
gave me hopes. I could do the
git add .
again. So I checked with git status what was about to happen. The Assets/_Scenes/Nobi/T-2/LightingData.asset file was appearing nowhere. So I pushed again, waited about 3 hour for it to do something just to see that it fails again.
What can I do?