Search
Write a publication
Pull to refresh

Comments 5

которые еще в начале двухтысячных написали книгу «Git для профессионального программиста»

Интересно, как можно написать книгу о гите в начале 2000-х годов, если его разработка в принципе только началась в 2005 году?

Да так же как и требовать 5+ лет опыта для двухлетней технологии.

Может, автор мыслит в масштабах тысячелетия (2000-2999).

По словам Чакона и Штрауба, Git отличается от других СКВ подходом к работе с данными: такие системы, как Subversion, CVS, Perforce и Bazzar, хранят информацию в виде списка изменений в файлах (это также называется контролем версий на основе различий), а Git обрабатывает данные в виде набора снимков.


Можно дополнить, чтобы не складывалось впечатление, что git самая совершенная система:

Такие системы как darcs — в виде набора патчей.
Что имеет преимущества над системой снимков в каких то случаев.

There are basically two approaches to version control: either snapshot-based (git, mercurial, svn, or their ancestors), or patch-based (darcs). Historically, patch-based systems have been very simple to learn and use, but slow, whereas snapshot-based systems can be extremely fast, but are usually hard to use for more than simple operations. As an example, cherry-picking does not work well in git/mercurial, and merging is sometimes plain wrong.


In Git, cherry-picking means taking some commits, but not all, from another branch. This causes these commits to be rebased onto the current branch, losing their identity in the process. It usually works fine the first time it’s done, but then creates artificial conflicts if you want to cherry-pick again between the same branches, for no real reason.

We call that counter-intuitive, because it’s a fairly common workflow: many projects have branches name “stable” and “master”, and backport bugfixes from master into stable.


Есть и гибридные в этом смысле CVS со своими преимуществами над git. Например, pijul (но он поближе к патчевым):
Pijul combines these approaches, by representing its data in a more general way than snapshot-based systems, that allows for a patch-based interface.
Sign up to leave a comment.