Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[META] Repo size over 1GB #2291

Open
goffxnca opened this issue Nov 11, 2024 · 2 comments
Open

[META] Repo size over 1GB #2291

goffxnca opened this issue Nov 11, 2024 · 2 comments
Assignees
Labels
enhancement New feature or request

Comments

@goffxnca
Copy link
Contributor

Is your feature request related to a problem? Please describe.
not exactly a feature request, but i noticed the repo is over 1 GB right after cloning, which feels pretty big for a docs project. maybe it comes from large files or old artifacts hanging around in the .git history.
image

Describe the solution you'd like
i think maybe a history cleanup to get rid of any big or outdated files could be worth it.

Additional context
i checked for large files in the repo history, and here’s what came up:

git rev-list --objects --all | git cat-file --batch-check='%(objecttype) %(objectname) %(objectsize) %(rest)' | sed -n 's/^blob //p' | sort --numeric-sort --key=2 | cut -c 1-12,41- | numfmt --field=2 --to=iec | tail -n 10

8d775968d852    9.3M website/build/vi/ts.worker.js
f7d42abd0ce4    9.3M website/build/zh-CN/ts.worker.js
8a3b535b2b91      10M docs/assets/ledger-mobile.gif
9873bfdbc146      12M website/build/assets/images/drawing-da1faed841bf6cdd04ef58ac661fc935.svg
b6bc8ffaf007      14M website/build/assets/images/drawing-26c4dc1344e7ded8ff6d12b6652e6788.svg
1c5372b39452      15M website/build/assets/images/drawing-c60718c18458bad7704e13baf87fb838.svg
bde38a8768dc      15M website/static/docs/assets/welcome-pages/drawing.svg
3a29c7e23132      20M website/build/assets/images/drawing-9dfd2072c04c4601eb4a98aa5b13a8ec.svg
a2d06f34d776      20M website/static/docs/assets/welcome-pages/drawing.svg
373540bf40ea      25M website/static/docs/assets/QAPIScreen.gif

most of these files aren’t in the main repo anymore, they’re still in .git and adding to the size. the only large file still in use is drawing.svg (20 MB), which is still too big for the web ideally it’d be around 50 or 200KB max.

also, when i checked dir sizes at root, .git alone was already 1 GB 👀

du -sh * .[^.]* | sort -h

4.0K	.gitignore
4.0K	CODE_OF_CONDUCT.md
4.0K	CONTRIBUTING.md
4.0K	LICENSE-MIT.txt
4.0K	LOCALIZATION.md
4.0K	README.md
4.0K	yarn.lock
 12K	LICENSE-APACHE.txt
 48K	.github
 80K	blog
3.0M	docs
125M	website
1.0G	.git

feel free to dive in further!

@goffxnca goffxnca added the enhancement New feature or request label Nov 11, 2024
@github-project-automation github-project-automation bot moved this to NEW❗ in DevRel Nov 11, 2024
@bucanero
Copy link
Collaborator

I think this is because we are deploying the docs site to the build branch. If you only checkout the master branch you shouldn't get 1 GB download.

@gagdiez gagdiez assigned matiasbenary and bucanero and unassigned matiasbenary Nov 19, 2024
@thisisjoshford thisisjoshford moved this from NEW❗ to Ready for development ✅ in DevRel Nov 20, 2024
@gagdiez gagdiez moved this from Ready for development ✅ to In Progress 🏗️ in DevRel Nov 25, 2024
@goffxnca
Copy link
Contributor Author

you shouldn't get 1 GB download

hi @bucanero
just tested out cloning only master branch like suggested, turns out size is only 203.63 MB✅
and not 1 GB. so seems like the repo should be fine as is. thx again for taking the time to look into this!
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: In Progress 🏗️
Status: No status
Development

No branches or pull requests

3 participants