Reputation: 5901
I have two hard drives that I boot from. I switch back and forth between them right now because I'm playing with Archlinux on one of them.
The home partitions on these drives are "cloned" with rsync. Among other things there are a couple of Git repositories on the drives. Are there any downsides of doing this? Could I corrupt my repositories when pushing and pulling because I just copied the repos from one disk to another instead of use Git to clone them from my Git server?
Upvotes: 1
Views: 2478
Reputation: 44
This is just fine and will not corrupt anything.
Since git keeps everything onsite untill push and pull are issued, and everything is kept in the .git folder, a copyed repository will be the same as a cloned one, and in theory, you could actually copy that folder to multiple computers if you wanted to. This is one of the many features of git being a DCVS
Upvotes: 2
Reputation: 1513
I think it should work fine. But you can always git clone file://yourRepo
Read up: Git local protocol
Upvotes: 2