git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Questions about git-push for huge repositories
@ 2015-09-06  8:16 Levin Du
  2015-09-06 17:48 ` Junio C Hamano
  0 siblings, 1 reply; 9+ messages in thread
From: Levin Du @ 2015-09-06  8:16 UTC (permalink / raw)
  To: git; +Cc: Levin Du

Hi all,

I meet with a strange problem:

I've two repositories, with sizes:
  - A:  6.1G
  - B:  6G

Both A & B have been 'git gc' with:
  git reflog expire --expire=now --all
  git gc --prune=now --aggressive

Since A & B share many common files, to save disk space, I'd like to merge them:
(note: branch of A & B are independent, i.e. have no common ancestor.)
   git clone --bare A  C
   (cd B; git push ../C master:master_b)

Repo C's size has grown to 12G. Doing a 'git gc' again, it drops to 6.2G.

I expect that 'git push' push only new files and commits, which will
save lots of space.
Yet it turns out I'm wrong. Since Repo A has been published, pushing branch of B
will double the repo size, which is impossible for the storage limit.

Any suggestions? Thanks in advance.

Best Regards,
Levin Du

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2015-09-08 21:55 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-09-06  8:16 Questions about git-push for huge repositories Levin Du
2015-09-06 17:48 ` Junio C Hamano
2015-09-07  1:05   ` Levin Du
2015-09-07  3:51     ` Levin Du
2015-09-08  1:30       ` Levin Du
2015-09-08  5:44         ` Jeff King
2015-09-08 18:24           ` Junio C Hamano
2015-09-08 21:54             ` Jeff King
2015-09-08  5:00     ` Jeff King

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).