[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Centralized darcs

On Wed, Aug 02, 2006 at 10:17:57AM +0200, Christoph Haas wrote:
> On Tuesday 01 August 2006 23:47, John Goerzen wrote:
> > I do use darcs to track patches against upstream.  I really don't
> > understand the whole cdbs/dpatch/whatever thing -- why use a hack to
> > manage your patches when you could use a real VC tool that does it
> > better?
> Is there a common "best practice" procedure on how to deal with new 
> upstream releases then? I imagine that I unpack an upstream tarball, put 
> it under (D)RCS control and work on the debian/ directory. Then a new 
> upstream tarball is released. Do I just unpack it and do a merge? How do 
> tell my own patches (that I usually do in dpatch) from the upstream 
> changes?

I generally keep an upstream branch and a Debian branch.  I wrote a few
simple tools in the darcs-buildpackage package to help with this.

dbp-importorig takes a tarball/directory name, a version number, and a
path to an upstream branch.  It commits the upstream changes vs. the
latest version in the upstream repo and tags it.

If upstream uses darcs or git, you could use their repo directly.  If
they use CVS or SVN, you could use tailor to track it.  If they use
Arch, you can use arch2darcs to track it.

Then all you do is go to your Debian branch and do a merge from the
upstream branch (darcs pull).  Most things will be merged automatically.
Conflicts will be warned as appropriate.

You do all your work in the Debian branch, committing changes as you go.

dbp-importorig always generates predictable commit messages.  Darcs has
support for regexps at a fundamental level in almost all commands, so
you can easily select (or not) the upstream patches.  What's more, the
Debian branch is always a superset of the upstream branch.  You can
extract the pure upstream sources at will from the Debian branch by
simply selecting the latest upstream tag from it.

-- John

Reply to: