views:

194

answers:

2

It's not uncommon for me to record a patch, pull it into my staging branch and then realize I've done something small and silly like a typo in a logging message, or something similarly trivial which doesn't require (to my mind) a whole new patch.

In these instances, I've been using:

darcs amend-record

To update the patch. But when I re-pull darcs will treat the patches as conflicting, so I end up having to unrecord and revert the patch in the staging branch, and then pull it again.

Is there a darcs command or option that will allow me to more simply pull an amended patch?

+2  A: 

You could try first running darcs unpull on the staging branch then pulling in the amended patch.

drewrichards
+2  A: 

Not really. Amending a patch makes it into a different patch, even though the name is the same as before. amend-record is normally used only in the local repo, before the patch has been pushed/pulled elsewhere. If the patch has been pushed to other repos, you'll need to obliterate it in those, and re-pull the amended version. (obliterate is the modern spelling of "unpull").

Alternately, use the rollback command; this is more friendly when the repos in question are public and used by multiple developers.

Simon Michael