Why is a bare git repo 1/4 the size of a non-bare? -


I have cloned a local repo in two separate repos: one bare and one non-bare bare 750 MB And non-bare 3 GB as I can "convert" freely between two, the same information should be both in both bare and unrivaled stores. So how can the non-banner be four times bigger once?

I think it should be doubled, because every file needs to be in both .git and work directory. But why four times?

files stored in .git / objects are often packed. This means that they are compressed and do not combine with block boundaries. Rather, there are many small files in the checkout. I would not be surprised if the ratio is better when using better filing, such as better packing of smaller files such as BTRFF, therefore, both aspects of your .git / objects Meet together in the directory being relatively small. This happens when you have not forgotten for git gc ; -)

Comments

Popular posts from this blog

python - how we can use ajax() in views.py in django? -

matlab - Using loops to get multiple values into a cell -

python - Sequence Pattern recognition with Pybrain -