I recently set up a repo with git lfs (I am working on a specific branch). When I did this, I accidentally committed a lot more files with lfs than I had to thinking lfs will automatically filter files > 100 mb. This resulted in this email: "We wanted to let you know that you’ve used 80% of your data plan for Git LFS on your personal account". Then I undid LFS and redid lfs only for one file. But that led to "We wanted to let you know that you’ve used 80% of your data plan for Git LFS on your personal account". I recognized my error and correctly untracked the LFS files I did not want in LFS. However, the storage has not decreased. When I run git lfs ls-files now it only shows the one file that I need to be tracked. Will the storage eventually go down? Is there anything else I should be doing?
I used the steps here: /
I was expecting the LFS storage to go down but it did not.
I recently set up a repo with git lfs (I am working on a specific branch). When I did this, I accidentally committed a lot more files with lfs than I had to thinking lfs will automatically filter files > 100 mb. This resulted in this email: "We wanted to let you know that you’ve used 80% of your data plan for Git LFS on your personal account". Then I undid LFS and redid lfs only for one file. But that led to "We wanted to let you know that you’ve used 80% of your data plan for Git LFS on your personal account". I recognized my error and correctly untracked the LFS files I did not want in LFS. However, the storage has not decreased. When I run git lfs ls-files now it only shows the one file that I need to be tracked. Will the storage eventually go down? Is there anything else I should be doing?
I used the steps here: https://www.ryangittings.co.uk/blog/removing-git-lfs-netlify/
I was expecting the LFS storage to go down but it did not.
Share Improve this question asked Nov 20, 2024 at 20:39 ShivangiShivangi 11 bronze badge 4- Git repositories contain history on older commits (you might say this is one of the main points of git). So you may need to clean up history too. Or if this is a brand new repository you just created with only a small number of files in it, you could just delete the repo and start over. – topsail Commented Nov 20, 2024 at 20:58
- Would you have some guidance on how to remove history? This is not a new project so I cannot delete the repo and start over. – Shivangi Commented Nov 20, 2024 at 21:05
- @topsail - there is a specific commit that committed the LFS change. If I "revert" commit changes will that help? – Shivangi Commented Nov 20, 2024 at 21:50
- 1 These instructions seem much better: removing-files-from-git-large-file-storage – topsail Commented Nov 21, 2024 at 0:27
1 Answer
Reset to default 1At this time, per Github documentation, after you remove files from Git LFS, the Git LFS objects still exist on the remote storage and will continue to count toward your Git LFS storage quota. To remove Git LFS objects from a repository, delete and recreate the repository. If you need to purge a removed object and you are unable to delete the repository, Github asks that you contact support for help.