Is it possible to host a bare Git repository using Dropbox, to share code?

I see no reason why it would lose data — Git’s repository structure is robust, and in the repository store itself, files with the same name will always have the same content (this doesn’t apply to branch names).

It’s not going to be efficient, though. Git’s transfer protocol means that it will usually only transfer a change once. With Dropbox, if two people pack slightly different repositories, the packs generated may contain significant common data while not being identical, so DropBox would sync both packs, which is inefficient.

You may also find that, although the data is all there, you wind up with un-tracked changes due to two copies both having the same branch updated at the same time. This can be worked around by ensuring that you push to different branches from each copy, but it’d be a pain.

Leave a Comment