Determining the size of the `.git` for a GitHub repo, without cloning it 0 ▲ Jamie Tanna 53 minutes ago · Tech · hide Every so often, I'll be doing work that needs to know how big a Git repo is. Right now, I'm doing some work in Renovate around how we support large repos and/or monorepos, and have hit the same question - "how big is that repo's .git folder", which gives an important guide for the minimum disk requirement needed for that repo. (I thought I'd already blogged about this, but it seems like I hadn't) A more convenient method is to use the GitHub API to look up that metadata, without needing to go through the pain of cloning it - even bloblessly - where we can instead: gh api /repos/renovatebot/renovate --jq .size 172111 # ~168M Per the docs: The size of the repository, in kilobytes. Size is calculated hourly. When a repository is initially created, the size is 0. We can see that if we clone the repo, we get a fairly similar number: % git clone https://github.com/renovatebot/renovate % du --summarize --apparent-size --human-readable renovate/.git 177M # and with everything checked out % du… Commenting on Bubbles has been removed. Why? If you want to talk about this post, write to the author, use the comments on their blog if it has them, or reply with a "RE:" post on your own blog. Suggestions? feedback@bubbles.town