Darcs

Last updated
Darcs
Original author(s) David Roundy
Developer(s) Guillaume Hoffmann, et al.
Initial releaseMarch 3, 2003;20 years ago (2003-03-03) [1]
Stable release
2.16.5 [2]   OOjs UI icon edit-ltr-progressive.svg / 20 February 2022;2 years ago (20 February 2022)
Repository
Written in Haskell
Operating system Unix, Linux, BSD, Apple macOS, MS Windows
Type Version control
License GPL-2.0-or-later
Website darcs.net   OOjs UI icon edit-ltr-progressive.svg

Darcs is a distributed version control system created by David Roundy. Key features include the ability to choose which changes to accept from other repositories, interaction with either other local (on-disk) repositories or remote repositories via SSH, HTTP, or email, and an unusually interactive interface. The developers also emphasize the use of advanced software tools for verifying correctness: the expressive type system of the functional programming language Haskell enforces some properties, and randomized testing via QuickCheck verifies many others. [3] The name is a recursive acronym for Darcs Advanced Revision Control System. [4]

Contents

Model

Darcs treats patches as first-class citizens. For the user, a repository can be seen as a set of patches, where each patch is not necessarily ordered with respect to other patches, i.e. the set of patches is only a partially ordered set. In many cases patches can be independently transmitted between various repositories.

Many branching, merging, and cherry-picking operations that would require additional commands with snapshot-based systems like Git or Mercurial can be directly done with Darcs with the usual "pull" and "push" commands. In terms of user interface, this means that Darcs has fewer commands. These commands are more interactive: one can choose more precisely which patches they want to exchange with remote repositories.

The patches of a repository are linearly ordered. Darcs automatically calculates whether patches can be reordered (an operation called commutation), and how to do it. These calculations implement a so-called "patch theory".

A Darcs patch can contain changes of the following kinds:

The notion of dependency between patches is defined syntactically. Intuitively, a patch B depends on another patch A if A provides the content that B modifies. This means that patches that modify different parts of the code are considered, by default, independent. To address cases when this is not desirable, Darcs enables the user to specify explicit dependencies between patches.

Since version 2.10, Darcs uses patience diff by default.

History

Darcs evolved out of David Roundy's efforts to design a new patch format for GNU arch in June 2002. These discussions didn't lead to any code being committed to Arch, but did lead to the conception of the theory of patches. After writing an initial version of Darcs in C++, the Haskell version was written in Autumn 2002 and released to the public in April 2003. Darcs 2.0 was released in April 2008 and introduced a more robust repository format, as well as a new patch semantic called "darcs-2", aimed at minimizing exponential merge conflicts. [5] The current development strategy focuses on implementing optimizations and adding new features, while maintaining the same repository format.

Shortcomings

Darcs has been criticized on the grounds of performance. [6] [7] One of the most notable challenges related to the merge algorithm in Darcs 1.x, which could do exponential work to merge some conflicts. Although it was not completely corrected in Darcs 2, [8] the frequency of exponential merges has been reduced. Bugs still remain in which merging of recursive conflicts fails. [9]

The revision control system Pijul [10] solves those complexity problems by making conflicts and their resolutions first class citizens which can commute with other changes.

See also

Related Research Articles

The Comprehensive Perl Archive Network (CPAN) is a repository of over 250,000 software modules and accompanying documentation for 39,000 distributions, written in the Perl programming language by over 12,000 contributors. CPAN can denote either the archive network or the Perl program that acts as an interface to the network and as an automated software installer. Most software on CPAN is free and open source software.

Concurrent Versions System is a version control system originally developed by Dick Grune in July 1986.

<span class="mw-page-title-main">Package manager</span> Software tools for handling software packages

A package manager or package-management system is a collection of software tools that automates the process of installing, upgrading, configuring, and removing computer programs for a computer in a consistent manner.

In software engineering, version control is a class of systems responsible for managing changes to computer programs, documents, large web sites, or other collections of information. Version control is a component of software configuration management.

In software development, when software has been forked or uses a chain of libraries/dependencies, upstream refers to an issue that occurs in software related to the chain. It is the direction that is toward the original authors or maintainers of software. It is usually used in the context of a version, a bug, or a patch.

<span class="mw-page-title-main">Portage (software)</span> Gentoo package management system

Portage is a package management system originally created for and used by Gentoo Linux and also by ChromeOS, Calculate, Sabayon, and Funtoo Linux among others. Portage is based on the concept of ports collections. Gentoo is sometimes referred to as a meta-distribution due to the extreme flexibility of Portage, which makes it operating-system-independent. The Gentoo/Alt project was concerned with using Portage to manage other operating systems, such as BSDs, macOS and Solaris. The most notable of these implementations is the Gentoo/FreeBSD project.

<span class="mw-page-title-main">Wget</span> Computer command line program for downloading

GNU Wget is a computer program that retrieves content from web servers. It is part of the GNU Project. Its name derives from "World Wide Web" and "get". It supports downloading via HTTP, HTTPS, and FTP.

Maven is a build automation tool used primarily for Java projects. Maven can also be used to build and manage projects written in C#, Ruby, Scala, and other languages. The Maven project is hosted by The Apache Software Foundation, where it was formerly part of the Jakarta Project.

<span class="mw-page-title-main">Git</span> Software for version control of files

Git is a distributed version control system that tracks changes in any set of computer files, usually used for coordinating work among programmers who are collaboratively developing source code during software development. Its goals include speed, data integrity, and support for distributed, non-linear workflows.

<span class="mw-page-title-main">Continuous integration</span> Software development practice based on frequent submission of granular changes

In software engineering, continuous integration (CI) is the practice of merging all developers' working copies to a shared mainline several times a day. Nowadays it is typically implemented in such a way that it triggers an automated build with testing. Grady Booch first proposed the term CI in his 1991 method, although he did not advocate integrating several times a day. Extreme programming (XP) adopted the concept of CI and did advocate integrating more than once per day – perhaps as many as tens of times per day.

In software development, distributed version control is a form of version control in which the complete codebase, including its full history, is mirrored on every developer's computer. Compared to centralized version control, this enables automatic management branching and merging, speeds up most operations, improves the ability to work offline, and does not rely on a single location for backups. Git, the world's most popular version control system, is a distributed version control system.

<span class="mw-page-title-main">Autopackage</span> Linux package management system

Autopackage is a free computer package management system aimed at making it simple to create a package that can be installed on all Linux distributions, created by Mike Hearn around 2002.

<span class="mw-page-title-main">Merge (version control)</span>

In version control, merging is a fundamental operation that reconciles multiple changes made to a version-controlled collection of files. Most often, it is necessary when a file is modified on two independent branches and subsequently merged. The result is a single collection of files that contains both sets of changes.

Branching, in version control and software configuration management, is the duplication of an object under version control. Each object can thereafter be modified separately and in parallel so that the objects become different. In this context the objects are called branches. The users of the version control system can branch any branch.

In software development, version control is a class of systems responsible for managing changes to computer programs or other collections of information such that revisions have a logical and consistent organization. The following tables include general and technical information on notable version control and software configuration management (SCM) software. For SCM software not suitable for source code, see Comparison of open-source configuration management software.

A software repository, or repo for short, is a storage location for software packages. Often a table of contents is also stored, along with metadata. A software repository is typically managed by source or version control, or repository managers. Package managers allow automatically installing and updating repositories, sometimes called "packages".

The Debian build toolchain is a collection of software utilities used to create Debian source packages (.dsc) and Debian binary packages from upstream source tarballs.

In version control software, a changeset is a set of alterations packaged together, along with meta-information about the alterations. A changeset describes the exact differences between two successive versions in the version control system's repository of changes. Changesets are typically treated as an atomic unit, an indivisible set, by version control systems. This is one synchronization model.

<span class="mw-page-title-main">RPM Package Manager</span> Package management system

RPM Package Manager (RPM) is a free and open-source package management system. The name RPM refers to the .rpm file format and the package manager program itself. RPM was intended primarily for Linux distributions; the file format is the baseline package format of the Linux Standard Base.

References

  1. "Changelog for darcs". Hackage. Retrieved 2018-06-24.
  2. Error: Unable to display the reference properly. See the documentation for details.
  3. Roundy 2005, p. 2: ‘One of the problems I had with the initial C++ darcs was that I had no unit testing code. Within two weeks of the first darcs record, I started using QuickCheck to test the patch functions, and the same day I fixed a bug that was discovered by QuickCheck. QuickCheck makes it very easy to define properties that functions must have, which are then tested with randomly generated data.’
  4. Roundy, David (2008-10-21), "prefer recursive acronymn (sic) to embarrassing one", Darcs (Commit), Darcs Hub.
  5. "Two", Darcs
  6. Marlow, Simon (March 7, 2007), "Current status of Darcs", Darcs users (mailing list), OSUOSL.
  7. Fendt, Robert (January 9, 2009), "DVCS Round-Up: One System to Rule Them All?", Developer Network, vol. 1, Linux Foundation, archived from the original on 2009-02-28.
  8. "ConflictsFAQ", Wiki, Darcs.
  9. "Issue 1520 Irrefutable pattern failed for pattern Data.Maybe.Just a2", Bug Tracker, Darcs.
  10. Pijul web site