0

I am kind of new to modular programming and to git. I am working on a project in which I connect to the Kaggle API and download datasets. I ran the code and the specific dataset (*.csv) appeared in my project structure. Higlighted with red arrow. The dataset is quite huge. So i kind of didn't think about it much and commited it to Git and now when I try to push, or do something Git won't allow and gives this message:

""" remote: error: File matrix factorization/src/rating.csv is 658.37 MB; this exceeds GitHub's file size limit of 100.00 MB
remote: error: GH001: Large files detected. You may want to try Git Large File Storage - https://git-lfs.github.com.
To https://github.com/ """

I deleted the file from my project, and tried again but is still in queue, I don't know how else to remove it. I right click on it at the source control to delete it, but there's no such command nor anything. Any suggestions? ALSO there is nothing to commit, it is now asking for push/sync. Please note that i'm super new to this.

I tried to undo commit, didn't know if it would work and how many undo commits I had to do so I only did one, nothing happened.

Moving my file to trash from the files sections didn't remove it from the source control.

Pulling first had no effect also.

1

1 Answer 1

0

After some time nothing had worked, I even tried installing the BFG Repo-Cleaner Download. But also didn't work. So, I ensured that all my files are saved locally, and then I did this:

git filter-branch --tree-filter 'rm -f your\ file/path_to/heavy_file.csv' HEAD

git reflog expire --expire=now --all

git gc --prune=now --aggressive

git push origin main --force
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.