[darcs-users] Patch Theory in action
droundy at abridgegame.org
Thu Nov 20 14:02:00 UTC 2003
On Wed, Nov 19, 2003 at 06:43:46PM -0800, Kevin Smith wrote:
> There are a couple things I don't understand:
> 1) How did it figure out that the Change patch depended on the Modify
Do you mean Move patch rather than Modify? I don't see a reference to
a Modify patch... The Change patch didn't depend on the Move patch, since
it commutes with the Move patch. In darcs terminology a dependency means
that two patches won't commute. So the Change patch depends on the add
patch, but not the Move patch--which means you can't pull the Change patch
without also pulling the Add patch.
> 2) As a darcs user, how would I know when I should to manually specify a
First off, I haven't manually specified a dependency in ages. You only
need to specify one if you expect people to pull a subset of patches from
your repository, and you have a patch that won't work without a prior
patch, and they don't naturally depend on each other.
The situation where I imagine one would manually specify a dependency is
when you have a series of changes that you expect to be moving from
repository to repository together. I imagine something like the preemptive
kernel patch in linux (which is now in the mainline kernel), which included
many changes throughout the kernel, and wasn't included in Linus' kernel
until it had gotten a lot of testing, but did get included in various other
people's trees. If the kernel developers were all using darcs, it would be
nice to have the preemptive kernel patches all have appropriate
dependencies defined, so you can pull them from one repo to another without
specifying each preemptive subpatch, and without getting a broken kernel
due to a patch you failed to pull which was required by one you did pull.
Another way to get a similar effect to manually specifying dependencies is
create a tag, which depends on all patches currently in the repo.
More information about the darcs-users