版本管理: Git的优点

Git作为一款强大的版本管理工具,以其快速、本地化、分布式的特点脱颖而出。它允许便捷的本地分支操作,离线工作,以及灵活的工作流适应。此外,Git在多个知名项目中被广泛采用,如Android、Linux内核等,成为新的行业标准。


Cheap Local Branching/ 方便建立本地分支

这也是Git与其他SCM(软件配置管理系统)最显著的区别。 其他SCM的分支可能仅仅是repository(库)的一个克隆而已。

Git可以拥有多个独立的本地分支,快捷的进行增删合并。

重要的是,当push到远程库时,可以只选择其中一个分支,而不是所有分支。

Everything is Local/ 一切都在本地

可以离线工作!除了fetch,pull,push少数才需要网络。

例如你可以将修改后的版本同任意历史版本比较


Git is Fast/就是快!


Git
Hg Bzr
Init 0.024s 0.059s 0.600s
Add 8.535s 0.368s 2.381s
Status 0.451s 1.946s 14.744s
Diff 0.543s 2.189s 14.248s
Tag 0.056s 1.201s 1.892s
Log 0.711s 2.650s 9.055s
Commit (Large) 12.480s 12.500s 23.002s
Commit (Small) 0.086s 0.517s 1.139s
Branch (Cold) 1.161s 94.681s 82.249s
Branch (Hot) 0.070s 12.300s 39.411s


Git is Small/ 占用空间小

  Git Hg Bzr SVN
Repo Alone 24M 34M 45M  
Entire Directory 43M 53M 64M 61M


The Staging Area/  集结待命区

你可以在此设置是上传所有更改,还是只上传其中一部分。



Distributed/  分布式

意味着多个完整备份,再也不用担心代码丢了。 而且Git是所有分布式SCM中速度最快的。

Any Workflow/ 任意工作流
由于Git是天生的分布式而且有良好的分支功能,因此可以适应多种工作流
包括: 中央式 / 集中管理式 /司令和副官式

GitHub

不只是放代码的主站,更是一个社交网络

Easy to Learn

Git is the new standard/ Git是新的标准

下面都是

  • Android
  • Apache Software Foundation (At least they officially mirror to Git.)
  • Debian (almost all packages, if a DVCS is used)
  • Drupal
  • Eclipse
  • Fedora
  • Gnome
  • KDE
  • The Linux Kernel of course ...
  • Perl
  • PHP (decided to migrate to Git)
  • PostgreSQL
  • Qt
  • Ruby on Rails (and it seems the Ruby world in general prefers Git)
  • all freedesktop.org projects, including X.org

参考:

如何高效利用Git

http://www.yangzhiping.com/tech/github.html


Git简易入门

http://rogerdudler.github.io/git-guide/index.zh.html


为什么Git胜过其他?

http://thkoch2001.github.io/whygitisbetter/#cheap-local-branching



评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值