我应该如何/应该在我的环境中使用 git?

发布于 2024-10-16 20:40:37 字数 487 浏览 4 评论 0原文

我正在考虑加入 Git 潮流。我的环境由 1-4 台 Windows 客户端计算机和一台 FreeNAS 服务器组成。

我需要什么才能让 Git 在这种类型的配置中工作?

服务器上是否需要安装任何 Git 软件? (例如,在 CVS 中,如果存储库作为 Windows (SMB) 共享进行访问,我不需要安装任何软件)。

如果我已经安装了 Cygwin,我应该在客户端计算机 (Windows) 上安装什么?是否有预编译的 git.exe(就像 cvs.exe 一样)占用的空间比建议的 130MB 少得多 MSysGit

我真的需要编译 Git 二进制文件才能在我的 Windows 客户端上使用 Git 吗?

我完全不知道从 CVS 范式到 Git 范式的转变意味着什么。

I am contemplating a jump into the Git bandwagon. My environment is made from 1-4 Windows client machines and a single FreeNAS server.

What do I need to make Git work in this type of configuration?

Is there any Git software that I need to install on the server? (in CVS, for example, I don't need to install any software, if the repository is accessed as a Windows (SMB) share).

What do I install on the client machine (Windows) if I already have Cygwin installed? Is there a pre-compiled git.exe (just like cvs.exe) which takes much less space than the proposed 130MB MSysGit?

Do I really have to go through compiling Git binaries in order to have Git on my Windows client?

I am totally clueless as to what the move from the CVS paradigm to the Git paradigm entails.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

新一帅帅 2024-10-23 20:40:37

Git 与 svn 或 cvs 不同,因为它是“完全分布式”,所以实际上并没有
客户和服务器,只是节点。在您的情况下,您需要让“客户端计算机”指向 NAS 上的远程存储库,以便他们可以在其中推送更改。您可以使用多种方法(包括文件)指向此存储库,如下所述:

http://www.kernel.org/pub/software/scm/git/docs/git-push.html#URLS

在 git 中,您的所有客户端也是节点,因此例如developer1可能在他的仓库中有一个实验分支,developer2 可以从中提取并进行审查。该分支不需要位于“服务器”上。这既令人困惑又强大。

最简单的开始就是遵循客户端/服务器模型。 4 个“客户端”将更改推送到共享文件服务器上的 git 存储库。

是否有预编译的git.exe(就像cvs.exe一样)

有,看这里,
http://oreilly.com/software-engineering/excerpts /version-control-git/installing-git.html

我还建议注册一个免费的 github.com 帐户,在一台机器上安装 git 并玩转,分叉其他项目,将它们拉下来,推上去等等...

如果你有一个小时的时间可以消磨时间,可以购买 http://peepcode.com/products/git屏幕截图虽然可以通过git行走。

Git is not the same as svn or cvs, since it is "Fully distributed", so there are not really
clients and server, just nodes. In your case you'll want to get your "client machines" pointing to a remote repo on the NAS, where they can push their changes. You can point to this repo using many methods including file, as outlined here:

http://www.kernel.org/pub/software/scm/git/docs/git-push.html#URLS

In git all your clients are nodes too, so for example developer1 might have a experimental branch in his repo that developer2 pulls from to review. This branch would not need to be on the "server". This is both confusing and powerful.

The easiest start to to just follow the client/server model to start with. 4 "clients" pushing changes up to a git repo on a shared file server.

Is there a pre-compiled git.exe (just like cvs.exe)

Yes, look here,
http://oreilly.com/software-engineering/excerpts/version-control-git/installing-git.html

I would also suggest signing up for a free github.com account, install git on one machine and play around, fork others projects, pull them down, push them up etc...

Maybe if you have an hour to kill buy the http://peepcode.com/products/git screencast to be walked though git.

徒留西风 2024-10-23 20:40:37

在我商店的计算机上,我只需:

  • 解压缩 Windows 版 Git 便携版(来自 msysgit 项目) ;少于 10Mo(与 130Mo msysgit 下载不同,它允许在 Windows 上重新编译 Git:您不需要它来完成您想做的事情)。
  • 更改 /etc/gitconfig 添加:
  • 使用 /git-cmd.bat/git-bash.bat 打开新的 DOS 窗口或 bash 会话在它们中设置了正确的PATH(并且仅在它们中,这意味着在这些shell之外不对用户PATH环境变量进行全局修改)。

On the computers in my shop, I simply:

  • unzip the portable edition of Git for Windows (from msysgit project); les than 10Mo (differs from the 130Mo msysgit downloads which allows to recompile Git on Windows: you don't need that for what you want to do).
  • change the <git install dir>/etc/gitconfig to add:
  • uses the <git install dir>/git-cmd.bat or the <git install dir>/git-bash.bat to open new DOS windows or bash sessions with the right PATH set in them (and in them only, meaning no global modification to the User PATH environement variable outside of those shells).
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文