views:

51

answers:

2

Hey all,

I was wondering how people deal with the fact that a git repo is really large and when I push the project to the web, copying the repo takes by far the majority of the time.

Thanks, Matt

+3  A: 

An entire repo only has to be cloned once. After you have received a majority of the files, only the ones that are changed get uploaded/downloaded.

So no, you should not keep your version control separate from your project. It is most convenient for you to be able to commit changes as you make them from the directory you are working in.

For git, changes are also committed locally (which is very fast), you only push/pull from the internet when you want to.

Tylo
Thanks, I'm a git noob. I was trying to FTP my git repo and it was taking forever. Didn't realize I just push and then I'm good to go. This is what I was looking for.
Matt
+3  A: 

If you use ssh:// or git:// access, pushing updates is much more efficient. Pushing over HTTP/WebDav is really slow.

Also, large git repos are less efficient than smaller ones at things like, for example, git grep. So try not to add large objects that don't really belong with your code (like tarballs).

phord
Thanks, it took me some research to figure out what you were saying cause I'm a git noob. But yah, thanks for the info, I found what I was looking for.
Matt