[darcs-users] Re: Using Darcs for Debian package maintenance

Juliusz Chroboczek jch at pps.jussieu.fr
Sun Jun 4 07:10:24 UTC 2006


Hi, Christoph,

> So I'm trying to find out whether Darcs is a good solution.

I believe it is.

> A number of Debian developers/maintainers seem to use Darcs.

Some do indeed.

  http://cl-debian.alioth.debian.org/cgi-bin/darcsweb.cgi

> I heard rumors (well, nobody could yet show me a working example)
> that keeping everything in the repository works well. They claim
> that way they do not lose changes of the upstream files because the
> RCS merges them into the new version. Actually I don't believe it
> would work well because new upstream version often change large
> parts and the patches could not be applied cleanly.

It depends how intrusive are the Debian patches.  If you work closely
with upstream, you'll most likely find a modus vivendi that avoids
conflicts.

If upstream doesn't use Darcs and integrates your patches, you get a
spurious conflict.  But it's easy to fix.

If both upstream and the packager use Darcs, everything is bliss and
happiness.

> - I cannot easily check in my changes into a central repository through
>   an HTTP proxy.

As Max noted, the simplest solution is to push over ssh.

If you want the gritty details, here's how we get the permissions
right on the darcs-unstable repository on darcs.net:

  - people allowed to push to darcs-unstable are in group darcs-unstable
    and have a umask of 002;
  - the darcs-unstable repository has the sticky bit set and belongs to
    darcs-unstable.

A future version of darcs will be able to automatically enforce the umask.

> - I read rumors that Darcs isn't yet stable enough for serious use

Darcs has two issues:

  (1) darcs likes to slurp the whole tree into memory;
  (2) darcs sometimes takes hours to make a complex merge.

Point (1) means that you need to have at least as much physical memory
as the size of your tree (don't use Darcs on your C64).  Point (2)
means that sometimes you'll need to perform a merge by hand (using
diff and patch).  It's happened to me exactly once in two years.

> - Darcs does not know about file permissions. [...] Is this a feature?

It's a missing feature.  Bug 54.

> - Some operations seem to mean changing files in the _darcs
> subdirectory manually. [...] This sounds like it's not only done in
> very rare cases where I have to override Darcs' default behavior but
> rather on a common basis.

No, it's only when you're unhappy with the default behaviour.  In
those cases, you can edit files in ~/.darcs (for per-user prefs) or in
_darcs/prefs (for per-repo prefs).

This is no different from editing ~/.emacs, and we like it that way.
If you have a good user-interface in mind, please file a bug and assign
it to Eric ;-)

> - I missed something like "svn stat" to see which files in the current
>   directory are under repository control.

You're right, it's a missing feature.  And I realise that neither
``darcs what -l'' nor ``darcs query manifest'' do what you want.

Could you please file a bug that describes the behaviour you want?

> Do you use [branches] often?

All the time.  I've got six branches of Darcs on this machine right
now:

  $ ls -F /usr/local/src/darcs/
  darcs/      darcs-git-temp/  darcs-unstable-git/
  darcs-git/  darcs-unstable/  darcs-unstable-old/

and I often create a temporary branch just to try something out.

> (I read a branch is a full copy of the repository's directory tree
> in the file system)

There are various hacks we use to hard-link files between branches,
but basically you're right.

> Sure you can tell me "if you are happy with Subversion then just
> stay there" but my race seeks perfection. :)

Stay with Subversion.  Actually, stay with CVS.  If you switch to a
modern system, you'll never be able to go back.

> Another choice might be Git+Cogito which I learned about a few days ago.

I consider Darcs and Git as the two reasonable choices for a software
project right now.

Darcs is simpler, more user-friendly, and I happen to believe more
powerful, but git is much faster.  It's pretty much an Emacs vs. vi
kind of choice.

I would recommend starting with Darcs, and then checking out Git once
you're feeling comfortable with distributed RC systems.

Happy hacking,

                                        Juliusz





More information about the darcs-users mailing list