5 ms·
How to use Dropbox as a git server?
- wladimir 16y agoDo note that, with multiple users that have write access and push at the same time, this can result in race conditions and corrupted repositories. So only use this for a personal repository, or when the others only have read access.
- AndrewDucker 16y agoAgreed. It's not running Git as a server, just putting the repository somewhere public.
- mbreese 16y agoNot only that, but you could have multiple users to begin with. Since all files are synced on save, two people couldn't be working at the same time. Well, I guess they could, but good luck editing the same file. Or even trying to commit. You could easily overwrite the other persons files without knowing it.
- JoelMcCracken 16y agoI've been doing this for a while now. I didn't even think anything of it.
- wccrawford 16y agoI think calling it a 'git server' is a bit much. Its only feature is to sync the repo between different computers. As wladimir pointed out, it's not even reliable when you have multiple committers.
- kjhgfhjkhgfv 16y agoIt does work for a central 'master' repository that people push/pull rarely when new versions are done but otherwise it's only good for a single user.
- almost 16y agoArticle could be summarized to one sentence "Put your git repo in your Dropbox". It does also go on to suggest that you share this folder with other Dropbox users but that's a bad idea. Even single users can end up with problems if they use multiple machines, git doesn't understand Dropbox's method of dealing with conflicts.
- agnoster 16y agoYeah, I think people may be overthinking this, although there's something to be said for "two great tastes that taste great together". It's kind of silly, but I actually wrote a "git dropbox" command to just stuff a bare repo of what I'm doing in my Dropbox so I don't have to think about it... and I kind of like it. Maybe it's overkill, but if I only have to type one command, it's easy enough I won't think about it :-) (https://github.com/agnoster/git-dropbox/ https://github.com/agnoster/git-dropbox/ for what it's worth) Agreed it's a dangerous idea for collaboration, unless you are the only one pushing to it and everyone else just pulls. That could work as a simple way to make your git repo pull-accessible to others without using a separate service or server (assuming you both have Dropbox already, of course).
- remi 16y agoHow is this different from http://news.ycombinator.com/item?id=2229756 http://news.ycombinator.com/item?id=2229756 (still on the frontpage) ?
- mrpollo 16y agoits not...
- philjackson 16y agoThis seems like a terrible idea. Not sure why it's getting so much attention, is it just because Dropbox is mentioned? https://git.wiki.kernel.org/index.php/GitHosting https://git.wiki.kernel.org/index.php/GitHosting is where I would say people should start if they want to host a .git.
- 3am 16y agoI completely agree. This is a perfect example of 'just because you can do it doesn't mean you should'.
- wtn 16y agoNext post: How to use Gitosis as a git server
- joemanaco 16y agohmmm.... I've used that together with a friend for quite some time now and we never had problems. I assume we were just lucky. Thank you people, for clearing that up. And yes, of course you're right, it's not really a server.