分布式版本控制系统真的没有集中存储库吗? [英] Does a Distributed Version Control System really have no centralised repository?

查看:33
本文介绍了分布式版本控制系统真的没有集中存储库吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这似乎是一个愚蠢的问题,但是您如何在没有服务器的情况下设置工作目录?企业如何保留一份安全的回购副本?

It might seem a silly question, but how do you get a working drectory set up without a server to check out from? And how does a business keep a safe backed up copy of the repo?

我假设那么必须有一个中央回购...但是它究竟是如何分发"的?我一直在想服务器-客户端 (SVN) 与对等-2-对等 (GIT) 的区别,但我不认为这是正确的,除非 GIT 之类的工具依赖于 Torrent 式技术?

I assume then there must be a central repo... but then how exactly is it 'distributed'? I always thought of a server-client (SVN) Vs peer-2-peer (GIT) distinction, but I don't believe that can be correct unless tools like GIT are dependent on torrent-style technology?

推荐答案

Re: 'torrent-style technology' - 您混淆了两个问题,一个是网络拓扑(点对点与服务器/客户端),另一个是服务器权限.这是可以理解的,因为术语几乎相同.但是分布式源代码控制并没有对网络连接模型提出任何要求 - 如果您愿意,可以通过电子邮件分发变更集.分布式版本控制的重要之处在于,每个人本质上都在运行自己的服务器并合并来自其他服务器的更改.当然,您需要能够从某处获得您的初始克隆,以及您如何知道某处"的位置超出了系统本身的范围.没有跟踪器"程序或任何东西——通常有人在某个地方有一个公共存储库,地址发布在网站上.但是一旦你克隆了它,你的副本就是一个完整的副本,能够成为其他人克隆的基础.

Re: 'torrent-style technology' - you're confusing 2 issues, one of network topology (peer to peer vs. server/client) and one of server authority. This is understandable because the terms are almost identical. But there's nothing about distributed source control that makes any requirements on the network connection model - you could be distributing changesets via email if you prefer. The important thing with distributed version control is that each person essentially runs their own server and merges changes in from the other servers. Of course, you need to be able to get your initial clone from somewhere, and how you know where that 'somewhere' is falls outside of the scope of the system itself. There is no 'tracker' program or anything - typically someone has a public repository somewhere with the address published on a web site. But once you've cloned it, your copy is a full one that is capable of being the basis for someone else's clone.

这篇关于分布式版本控制系统真的没有集中存储库吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆