goignore icon indicating copy to clipboard operation
goignore copied to clipboard

Problem with large repository

Open noornee opened this issue 2 years ago • 15 comments

We have a large repository; about (~ 11MB).

Screenshot

goignore_large_repo

This is because the binary file for goignore was accidentally? committed and even though its been deleted already, it's still in the github history.

I tried looking for way to remove a large file from a github history and most of what i found were kind of tricky for me to wrap my head around until i came accross this article

what do you think? @hacktivist123 @quamejnr @chuksgpfr @AdeboyeDN is there a better way to do this?

p.s. I created a random private repo to test this and it worked. I cant tell if its not going to cause some issues for a repo like this with forks..

noornee avatar Aug 05 '23 10:08 noornee

There's a way to delete it from the ~HEAD. I'll do it when I'm on my laptop.

chuksgpfr avatar Aug 05 '23 10:08 chuksgpfr

There's a way to delete it from the ~HEAD. I'll do it when I'm on my laptop.

alright, great! please when you do, i would love to see the git command you used. Tyyy ^^

noornee avatar Aug 05 '23 10:08 noornee

First i need to find the commit

chuksgpfr avatar Aug 05 '23 18:08 chuksgpfr

This commit committed a binary file

chuksgpfr avatar Aug 05 '23 18:08 chuksgpfr

Damn, that was me, I thought I deleted the binary. Please let me know how you deleted it if you do

hacktivist123 avatar Aug 05 '23 18:08 hacktivist123

This commit committed a binary file

@chuksgpfr The first commit also has a binary file committed to it

noornee avatar Aug 05 '23 18:08 noornee

still doing this @chuksgpfr ?

hacktivist123 avatar Aug 06 '23 14:08 hacktivist123

Yeah. I'll get it done today.

chuksgpfr avatar Aug 06 '23 14:08 chuksgpfr

Thanks my boss

hacktivist123 avatar Aug 06 '23 14:08 hacktivist123

I am back here. @noornee how did you see the size of the repo? I got 245KB

chuksgpfr avatar Aug 07 '23 17:08 chuksgpfr

I am back here. @noornee how did you see the size of the repo?

Welcome! I cloned and checked the size of the goignore directory with du

Screenshot

goignore_large_repo

... I got 245KB

strange. how did you check the size? or have you successfully run the git commands to purge the binary files from goignore's history ?

noornee avatar Aug 07 '23 17:08 noornee

Different sizes. The size that was downloaded from GitHub using this command curl https://github.com/hacktivist123/goignore > /dev/null | grep size | tr -dc '[:digit:]' is different.

chuksgpfr avatar Aug 07 '23 18:08 chuksgpfr

What are the sizes?

hacktivist123 avatar Aug 07 '23 19:08 hacktivist123

Different sizes. The size that was downloaded from GitHub using this command curl https://github.com/hacktivist123/goignore > /dev/null | grep size | tr -dc '[:digit:]' is different.

i dont think this command would give you the size of the github repo. it just downloads the webpage and prints the lines that matchs the size pattern and essentially outputs the digits.

ss

invalid

you could access the size of the repo using the github api.

i.e.

curl --silent https://api.github.com/repos/hacktivist123/goignore | grep size

p.s. the size it would give you would be in kilobytes. but its approximately 11MB

noornee avatar Aug 07 '23 20:08 noornee

What are the sizes?

you could check the size of the repo with a GUI filemanager. the size is approx 11MB.

SCREENSHOT

thunar_goignore_size

noornee avatar Aug 07 '23 20:08 noornee