Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Is my "Large Repository" all .git?

lasmit December 22, 2020

I have a repository which is very close to being full: https://cln.sh/S1Hv5d

When I analyse disk use on my machine, it seems that the `.git` folder is using the vast majority of space: https://cln.sh/UwRS1g

I've run `git repack -a -d --depth=250 --window=250`  which did seem to reduce the local file size by several hundred MB, but after pushing, I still see being 0.05 GB away from being over the limit.

The article here: https://support.atlassian.com/bitbucket-cloud/docs/reduce-repository-size/ doesn't mention `.git` at all.

I am quite happy to reduce the size of my repo, but I'm not clear on how to do that.

Any guidance would be appreciated!

1 answer

0 votes
Theodora Boudale
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
December 28, 2020

Hi @lasmit ,

The .git folder is essentially the repository, it's where Git stores the files of your repo, commits, tags, etc.

When you clone a repo locally, the directory that is created contains a .git folder and the rest of the files/folders in this directory are the working directory, i.e. the files and folders at the latest commit of the branch that is checked out.

If you give me the URL of the repo, I can run a git gc on it, this may be enough to reduce the repo's size. If you don't feel comfortable sharing it here publicly, you can open a ticket with the support team via https://support.atlassian.com/contact/#/ and request a git gc for your repo. In "What can we help you with" select "Technical issues and bugs" and then Bitbucket Cloud as product.

If the git gc does not reduce the repo's size (or if you'd still like to reduce it further), I'll be more than happy to explain the options and how to do this (or you can ask the engineer who will be handling your support ticket, if you choose to open one). I would suggest running the git gc first though, as this may be enough.

Kind regards,
Theodora

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events